Commit 08a3c6aa authored by huyuchen's avatar huyuchen

huych-含风险项目商险不购买申请提交

parent 51a8fbc6
...@@ -216,6 +216,33 @@ public class TInsuranceUnpurchaseApplyServiceImpl extends ServiceImpl<TInsurance ...@@ -216,6 +216,33 @@ public class TInsuranceUnpurchaseApplyServiceImpl extends ServiceImpl<TInsurance
setValue(tInsuranceUnpurchaseApply,user,tInsuranceUnpurchaseApply.getApplyNo()); setValue(tInsuranceUnpurchaseApply,user,tInsuranceUnpurchaseApply.getApplyNo());
tInsuranceUnpurchaseApply.setCreateTimeZc(LocalDateTime.now()); tInsuranceUnpurchaseApply.setCreateTimeZc(LocalDateTime.now());
baseMapper.updateById(tInsuranceUnpurchaseApply); baseMapper.updateById(tInsuranceUnpurchaseApply);
if (tInsuranceUnpurchaseApply.getAuditFlag().equals(CommonConstants.ZERO_STRING)) {
// 记录提交审核日志
TAuditRecord submitAuditRecord = new TAuditRecord();
submitAuditRecord.setDomainId(tInsuranceUnpurchaseApply.getId());
submitAuditRecord.setFlowId(CommonConstants.EMPTY_STRING);
submitAuditRecord.setNodeId(CommonConstants.EMPTY_STRING);
submitAuditRecord.setApprovalMan(user.getId());
submitAuditRecord.setApprovalManName(user.getNickname());
// 审批结果为“提交”
submitAuditRecord.setApprovalResult(CommonConstants.dingleDigitStrArray[3]);
submitAuditRecord.setDeleteFlag(CommonConstants.NOT_DELETE_FLAG);
submitAuditRecord.setApprovalTime(LocalDateTime.now());
// 审核记录标识 1当前审核记录
submitAuditRecord.setPreFlag(CommonConstants.ONE_STRING);
submitAuditRecord.setSubmitMan(user.getId());
submitAuditRecord.setSubmitManName(user.getNickname());
// 申请原因
// submitAuditRecord.setReason(reason);
// 审核类型
submitAuditRecord.setAuditType(CommonConstants.ZERO_STRING);
submitAuditRecord.setCreateTime(LocalDateTime.now());
// 提交节点名称
submitAuditRecord.setNodeName("提交即审核通过");
submitAuditRecord.setSubmitCreateTime(LocalDateTime.now());
submitAuditRecord.setEntityName(applyNo);
auditRecordService.save(submitAuditRecord);
}
//更新附件 //更新附件
updateFileId(tInsuranceUnpurchaseApply); updateFileId(tInsuranceUnpurchaseApply);
//先删除明细表数据再重新生成 //先删除明细表数据再重新生成
...@@ -243,6 +270,33 @@ public class TInsuranceUnpurchaseApplyServiceImpl extends ServiceImpl<TInsurance ...@@ -243,6 +270,33 @@ public class TInsuranceUnpurchaseApplyServiceImpl extends ServiceImpl<TInsurance
tInsuranceUnpurchaseApply.setCreateUserDeptId(user.getDeptId().toString()); tInsuranceUnpurchaseApply.setCreateUserDeptId(user.getDeptId().toString());
tInsuranceUnpurchaseApply.setApplyNo(applyNo); tInsuranceUnpurchaseApply.setApplyNo(applyNo);
baseMapper.insert(tInsuranceUnpurchaseApply); baseMapper.insert(tInsuranceUnpurchaseApply);
if (tInsuranceUnpurchaseApply.getAuditFlag().equals(CommonConstants.ZERO_STRING)) {
// 记录提交审核日志
TAuditRecord submitAuditRecord = new TAuditRecord();
submitAuditRecord.setDomainId(tInsuranceUnpurchaseApply.getId());
submitAuditRecord.setFlowId(CommonConstants.EMPTY_STRING);
submitAuditRecord.setNodeId(CommonConstants.EMPTY_STRING);
submitAuditRecord.setApprovalMan(user.getId());
submitAuditRecord.setApprovalManName(user.getNickname());
// 审批结果为“提交”
submitAuditRecord.setApprovalResult(CommonConstants.dingleDigitStrArray[3]);
submitAuditRecord.setDeleteFlag(CommonConstants.NOT_DELETE_FLAG);
submitAuditRecord.setApprovalTime(LocalDateTime.now());
// 审核记录标识 1当前审核记录
submitAuditRecord.setPreFlag(CommonConstants.ONE_STRING);
submitAuditRecord.setSubmitMan(user.getId());
submitAuditRecord.setSubmitManName(user.getNickname());
// 申请原因
// submitAuditRecord.setReason(reason);
// 审核类型
submitAuditRecord.setAuditType(CommonConstants.ZERO_STRING);
submitAuditRecord.setCreateTime(LocalDateTime.now());
// 提交节点名称
submitAuditRecord.setNodeName("提交即审核通过");
submitAuditRecord.setSubmitCreateTime(LocalDateTime.now());
submitAuditRecord.setEntityName(applyNo);
auditRecordService.save(submitAuditRecord);
}
//更新附件 //更新附件
updateFileId(tInsuranceUnpurchaseApply); updateFileId(tInsuranceUnpurchaseApply);
List<TInsuranceUnpurchasePerson> personInfoList = new ArrayList<>(); List<TInsuranceUnpurchasePerson> personInfoList = new ArrayList<>();
...@@ -361,35 +415,6 @@ public class TInsuranceUnpurchaseApplyServiceImpl extends ServiceImpl<TInsurance ...@@ -361,35 +415,6 @@ public class TInsuranceUnpurchaseApplyServiceImpl extends ServiceImpl<TInsurance
.last(CommonConstants.LAST_ONE_SQL)); .last(CommonConstants.LAST_ONE_SQL));
tInsuranceUnpurchaseApply.setAuditFlag(count > 0 ? CommonConstants.ZERO_STRING : CommonConstants.ONE_STRING); tInsuranceUnpurchaseApply.setAuditFlag(count > 0 ? CommonConstants.ZERO_STRING : CommonConstants.ONE_STRING);
tInsuranceUnpurchaseApply.setStatus(count > 0 ? CommonConstants.THREE_STRING : tInsuranceUnpurchaseApply.getStatus()); tInsuranceUnpurchaseApply.setStatus(count > 0 ? CommonConstants.THREE_STRING : tInsuranceUnpurchaseApply.getStatus());
if (tInsuranceUnpurchaseApply.getAuditFlag().equals(CommonConstants.ZERO_STRING)) {
// 记录提交审核日志
TAuditRecord submitAuditRecord = new TAuditRecord();
submitAuditRecord.setDomainId(tInsuranceUnpurchaseApply.getId());
submitAuditRecord.setFlowId(CommonConstants.EMPTY_STRING);
// submitAuditRecord.setNodeId(startProcessNode.getId());
submitAuditRecord.setApprovalMan(user.getId());
submitAuditRecord.setApprovalManName(user.getNickname());
// 审批结果为“提交”
submitAuditRecord.setApprovalResult(CommonConstants.dingleDigitStrArray[3]);
submitAuditRecord.setDeleteFlag(CommonConstants.NOT_DELETE_FLAG);
submitAuditRecord.setApprovalTime(LocalDateTime.now());
// 审核记录标识 1当前审核记录
submitAuditRecord.setPreFlag(CommonConstants.ONE_STRING);
submitAuditRecord.setSubmitMan(user.getId());
submitAuditRecord.setSubmitManName(user.getNickname());
// 申请原因
// submitAuditRecord.setReason(reason);
// 审核类型
submitAuditRecord.setAuditType(CommonConstants.ZERO_STRING);
submitAuditRecord.setCreateTime(LocalDateTime.now());
// 提交节点名称
submitAuditRecord.setNodeName("提交即审核通过");
submitAuditRecord.setSubmitCreateTime(LocalDateTime.now());
submitAuditRecord.setEntityName(applyNo);
auditRecordService.save(submitAuditRecord);
}
} }
} }
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment