diff --git a/ruoyi-system/src/main/java/com/ruoyi/wisdomarbitrate/service/mscase/impl/MsSignSealServiceImpl.java b/ruoyi-system/src/main/java/com/ruoyi/wisdomarbitrate/service/mscase/impl/MsSignSealServiceImpl.java index b76d13f..32c1ab2 100644 --- a/ruoyi-system/src/main/java/com/ruoyi/wisdomarbitrate/service/mscase/impl/MsSignSealServiceImpl.java +++ b/ruoyi-system/src/main/java/com/ruoyi/wisdomarbitrate/service/mscase/impl/MsSignSealServiceImpl.java @@ -392,6 +392,11 @@ public class MsSignSealServiceImpl implements MsSignSealService { if (nextFlow == null) { return AjaxResult.error("未找到下一个流程节点"); } + // 查询当前节点 + MsCaseFlow currentFlow = caseFlowMapper.selectByPrimaryKey(dto.getCaseFlowId()); + if (currentFlow == null) { + return AjaxResult.error("当前流程不存在"); + } if (StrUtil.isNotEmpty(dto.getBatchNumber())) { // 批量操作 // 查询该批号下该流程的案件 @@ -403,9 +408,7 @@ public class MsSignSealServiceImpl implements MsSignSealService { application.setCaseFlowId(nextFlow.getId()); application.setCaseStatusName(nextFlow.getCaseStatusName()); caseApplicationMapper.updateByPrimaryKeySelective(application); - CaseLogUtils.insertCaseLog(application.getId(), nextFlow.getNodeId(), nextFlow.getCaseStatusName(),"用印申请"); - - + CaseLogUtils.insertCaseLog(application.getId(), currentFlow.getNodeId(), currentFlow.getCaseStatusName(),"用印申请"); } } else { // 单独 @@ -415,9 +418,7 @@ public class MsSignSealServiceImpl implements MsSignSealService { application.setCaseFlowId(nextFlow.getId()); application.setCaseStatusName(nextFlow.getCaseStatusName()); caseApplicationMapper.updateByPrimaryKeySelective(application); - CaseLogUtils.insertCaseLog(application.getId(), nextFlow.getNodeId(), nextFlow.getCaseStatusName(),"用印申请"); - - + CaseLogUtils.insertCaseLog(application.getId(), currentFlow.getNodeId(), currentFlow.getCaseStatusName(),"用印申请"); } return AjaxResult.success("用印申请成功");