fix: scc流程提交后重复保存

This commit is contained in:
2024-07-18 15:38:22 +08:00
parent 015a9f8f9d
commit c448c59396
@@ -349,7 +349,7 @@ public class ProcessStandardComplianceCheckServiceImpl extends ServiceImpl<Proce
detail.setAuthDept(curUserDepartIds);
});
// 先删后增
removeByIds(detailInfoListIds);
sccDetailService.removeByIds(detailInfoListIds);
detailInfoList.forEach(detail -> detail.setValuationTime(new Date()));
detailInfoList.forEach(detail -> detail.setId(null));
sccDetailService.saveBatch(detailInfoList);
@@ -367,13 +367,13 @@ public class ProcessStandardComplianceCheckServiceImpl extends ServiceImpl<Proce
detail.setId(null);
});
// 先删后增
removeByIds(detailInfoListIds);
sccDetailService.removeByIds(detailInfoListIds);
sccDetailService.saveBatch(detailInfoList);
runtimeService.setVariable(processInstanceId, DESIGNER, curUserId);
break;
case MAIN_CHECK_USER_COLLECT:
// 先删后增
removeByIds(detailInfoListIds);
sccDetailService.removeByIds(detailInfoListIds);
detailInfoList.forEach(detail -> detail.setId(null));
sccDetailService.saveBatch(detailInfoList);
// 不分发直接设置后续审批节点的人员变量