From cfe0c93abd6c7e8e5ffcd390a941538427c6dd5a Mon Sep 17 00:00:00 2001
From: wxj334 <2241669945@qq.com>
Date: Mon, 26 Dec 2022 14:10:06 +0800
Subject: [PATCH] 2222

---
 ServiceSite/pom.xml                           |  2 +-
 .../command/incomeplan/InComePlanSvrImpl.java | 16 ++++--
 .../prediction/SaveYBKZMoneySvrImpl.java      | 21 ++++++--
 .../projectplan/ProjectPlanSvrImpl.java       | 11 +++-
 .../projectplan/domain/service/FlowSvr.java   | 31 +++++------
 .../domain/service/FlowSvrImpl.java           | 21 ++++----
 .../ProjectPlanQueryServiceImpl.java          | 53 ++++++++++++++-----
 .../infrastructure/rpc/FlowRpc.java           |  7 +--
 .../infrastructure/rpc/FlowRpcImpl.java       | 32 +++++------
 9 files changed, 126 insertions(+), 68 deletions(-)

diff --git a/ServiceSite/pom.xml b/ServiceSite/pom.xml
index df960b4c0..689436aea 100644
--- a/ServiceSite/pom.xml
+++ b/ServiceSite/pom.xml
@@ -85,7 +85,7 @@
         <dependency>
             <groupId>com.seasky</groupId>
             <artifactId>micro-flow-api</artifactId>
-            <version>1.0.2.23</version>
+            <version>2.0.6</version>
         </dependency>
 
         <dependency>
diff --git a/ServiceSite/src/main/java/com/seasky/projectplan/application/command/incomeplan/InComePlanSvrImpl.java b/ServiceSite/src/main/java/com/seasky/projectplan/application/command/incomeplan/InComePlanSvrImpl.java
index ff912514e..2a7b8afef 100644
--- a/ServiceSite/src/main/java/com/seasky/projectplan/application/command/incomeplan/InComePlanSvrImpl.java
+++ b/ServiceSite/src/main/java/com/seasky/projectplan/application/command/incomeplan/InComePlanSvrImpl.java
@@ -13,6 +13,7 @@ import com.seasky.micro.basedata.api.IUser;
 import com.seasky.micro.basedata.dto.RoleIdsAndOrganizationRequestDTO;
 import com.seasky.micro.basedata.dto.UserDTO;
 import com.seasky.microflowapi.api.IFlow;
+import com.seasky.microflowapi.dto.CommitProcessCmd;
 import com.seasky.projectplan.application.command.assembler.InComePlanAssembler;
 import com.seasky.projectplan.application.command.attachment.AttachmentSvr;
 import com.seasky.projectplan.application.query.baseconfig.BaseConfigQuerySvr;
@@ -268,8 +269,11 @@ public class InComePlanSvrImpl implements InComePlanSvr {
         aggIds.add(cmd.getId());
         InComePlanAgg inComePlanAgg = inComePlanRepository.queryInComePlanListByIds(aggIds).get(0);
         List<String> userCode = getAuditCodeByInfo(cmd.getNodeIds().get(0), cmd.getId());
+        CommitProcessCmd commitProcessCmd=new CommitProcessCmd();
+        commitProcessCmd.setUserCode(userCode);
+        commitProcessCmd.setFlowSubmitCmd(null);
         //璋冪敤娴佺▼鐨勫井鏈嶅姟鍥為€€
-        flowSvr.submitFLow(inComePlanAgg.getProcessId().toString(), null, cmd.getRemake(), userCode);
+        flowSvr.submitFLow(inComePlanAgg.getProcessId().toString(), null, cmd.getRemake(), commitProcessCmd);
         //鑾峰彇閫€鍥炲悗鐨勭姸鎬�
         String stateLabel = flowSvr.getStateLabelByProcessId(inComePlanAgg.getProcessId().toString());
         //鍥炲啓
@@ -293,8 +297,11 @@ public class InComePlanSvrImpl implements InComePlanSvr {
         InComePlanAgg inComePlanAgg = inComePlanRepository.queryInComePlanListByIds(aggIds).get(0);
 
         List<String> userCode = getAuditCodeByInfo(cmd.getNodeIds().get(0), cmd.getId());
+        CommitProcessCmd commitProcessCmd=new CommitProcessCmd();
+        commitProcessCmd.setUserCode(userCode);
+        commitProcessCmd.setFlowSubmitCmd(null);
         //璋冪敤娴佺▼鐨勫井鏈嶅姟鍥為€€
-        flowSvr.submitFLow(inComePlanAgg.getProcessId().toString(), cmd.getNodeIds().get(0).toString(), cmd.getRemake(), userCode);
+        flowSvr.submitFLow(inComePlanAgg.getProcessId().toString(), cmd.getNodeIds().get(0).toString(), cmd.getRemake(), commitProcessCmd);
         //鑾峰彇閫€鍥炲悗鐨勭姸鎬�
         String stateLabel = flowSvr.getStateLabelByProcessId(inComePlanAgg.getProcessId().toString());
         //鍥炲啓
@@ -311,8 +318,11 @@ public class InComePlanSvrImpl implements InComePlanSvr {
         InComePlanAgg inComePlanAgg = inComePlanRepository.queryInComePlanListByIds(aggIds).get(0);
         String nodeId = "sid-D4784941-DBF9-4BA0-863F-6BC7515878C3";
         List<String> userCode = getAuditCodeByInfo(nodeId, id);
+        CommitProcessCmd commitProcessCmd=new CommitProcessCmd();
+        commitProcessCmd.setUserCode(userCode);
+        commitProcessCmd.setFlowSubmitCmd(null);
         //璋冪敤娴佺▼鐨勫井鏈嶅姟鍥為€€
-        flowSvr.submitFLow(inComePlanAgg.getProcessId().toString(), nodeId, "鍒跺崟浜鸿嚜琛屽洖鎾�", userCode);
+        flowSvr.submitFLow(inComePlanAgg.getProcessId().toString(), nodeId, "鍒跺崟浜鸿嚜琛屽洖鎾�", commitProcessCmd);
         //鑾峰彇閫€鍥炲悗鐨勭姸鎬�
         String stateLabel = flowSvr.getStateLabelByProcessId(inComePlanAgg.getProcessId().toString());
         //鍥炲啓
diff --git a/ServiceSite/src/main/java/com/seasky/projectplan/application/command/prediction/SaveYBKZMoneySvrImpl.java b/ServiceSite/src/main/java/com/seasky/projectplan/application/command/prediction/SaveYBKZMoneySvrImpl.java
index 4b814a596..69f5a522a 100644
--- a/ServiceSite/src/main/java/com/seasky/projectplan/application/command/prediction/SaveYBKZMoneySvrImpl.java
+++ b/ServiceSite/src/main/java/com/seasky/projectplan/application/command/prediction/SaveYBKZMoneySvrImpl.java
@@ -9,6 +9,7 @@ import com.seasky.core.util.ExceptionUtil;
 import com.seasky.micro.basedata.api.IUser;
 import com.seasky.micro.basedata.dto.RoleIdsAndOrganizationRequestDTO;
 import com.seasky.micro.basedata.dto.UserDTO;
+import com.seasky.microflowapi.dto.CommitProcessCmd;
 import com.seasky.microflowapi.dto.FlowCanShowOut;
 import com.seasky.projectplan.application.command.assembler.PredictionAssembler;
 import com.seasky.projectplan.application.query.prediction.QueryYBInfoService;
@@ -549,8 +550,11 @@ public class SaveYBKZMoneySvrImpl implements SaveYBKZMoneySvr {
         }
 
         //璋冪敤娴佺▼鍚姩RPC
+        CommitProcessCmd commitProcessCmd=new CommitProcessCmd();
+        commitProcessCmd.setUserCode(getCodeList(actionFlowCmd.getNodeIds().get(0), actionFlowCmd.getId()));
+        commitProcessCmd.setFlowSubmitCmd(null);
         flowSvr.submitFLow
-                (projectPo.getProcessId().toString(), actionFlowCmd.getNodeIds().get(0), actionFlowCmd.getRemake(), getCodeList(actionFlowCmd.getNodeIds().get(0), actionFlowCmd.getId()));
+                (projectPo.getProcessId().toString(), null, actionFlowCmd.getRemake(), commitProcessCmd);
 
         //鑾峰彇娴佺▼鐘舵€�
         String stateLabelByProcessId = flowSvr.getStateLabelByProcessId(projectPo.getProcessId().toString());
@@ -774,8 +778,11 @@ public class SaveYBKZMoneySvrImpl implements SaveYBKZMoneySvr {
         }
 
         //璋冪敤鎻愪氦娴佺▼
+        CommitProcessCmd commitProcessCmd=new CommitProcessCmd();
+        commitProcessCmd.setUserCode(getCodeList(actionFlowCmd.getNodeIds().get(0), actionFlowCmd.getId()));
+        commitProcessCmd.setFlowSubmitCmd(null);
         flowSvr.submitFLow
-                (projectPo.getProcessId().toString(), actionFlowCmd.getNodeIds().get(0), actionFlowCmd.getRemake(), getCodeList(actionFlowCmd.getNodeIds().get(0), actionFlowCmd.getId()));
+                (projectPo.getProcessId().toString(), null, actionFlowCmd.getRemake(), commitProcessCmd);
 
         //鑾峰彇娴佺▼鐘舵€�
         String stateLabelByProcessId = flowSvr.getStateLabelByProcessId(projectPo.getProcessId().toString());
@@ -828,8 +835,11 @@ public class SaveYBKZMoneySvrImpl implements SaveYBKZMoneySvr {
             );
         }
         //璋冪敤RPC
+        CommitProcessCmd commitProcessCmd=new CommitProcessCmd();
+        commitProcessCmd.setUserCode(getCodeList(actionFlowCmd.getNodeIds().get(0), actionFlowCmd.getId()));
+        commitProcessCmd.setFlowSubmitCmd(null);
         flowSvr.backFlow
-                (projectPo.getProcessId(), actionFlowCmd.getNodeIds().get(0), actionFlowCmd.getRemake(), getCodeList(actionFlowCmd.getNodeIds().get(0), actionFlowCmd.getId()));
+                (projectPo.getProcessId(), actionFlowCmd.getNodeIds().get(0), actionFlowCmd.getRemake(), commitProcessCmd);
 
         //鑾峰彇娴佺▼鐘舵€�
         String stateLabelByProcessId = flowSvr.getStateLabelByProcessId(projectPo.getProcessId().toString());
@@ -890,8 +900,11 @@ public class SaveYBKZMoneySvrImpl implements SaveYBKZMoneySvr {
         }
         String nodeId = "sid-D4784941-DBF9-4BA0-863F-6BC7515878C3";
         //璋冪敤RPC   鑾峰彇褰撳墠鐧诲綍浜篶ode
+        CommitProcessCmd commitProcessCmd=new CommitProcessCmd();
+        commitProcessCmd.setUserCode(getCodeList(nodeId, id));
+        commitProcessCmd.setFlowSubmitCmd(null);
         flowSvr.recallFlow
-                (projectPo.getProcessId(), nodeId, "鍒跺崟浜鸿嚜琛屽洖鎾�", getCodeList(nodeId, id));
+                (projectPo.getProcessId(), nodeId, "鍒跺崟浜鸿嚜琛屽洖鎾�", commitProcessCmd);
 
         //鑾峰彇娴佺▼鐘舵€�
         String stateLabelByProcessId = flowSvr.getStateLabelByProcessId(projectPo.getProcessId().toString());
diff --git a/ServiceSite/src/main/java/com/seasky/projectplan/application/command/projectplan/ProjectPlanSvrImpl.java b/ServiceSite/src/main/java/com/seasky/projectplan/application/command/projectplan/ProjectPlanSvrImpl.java
index c1036a39d..ec669e6b7 100644
--- a/ServiceSite/src/main/java/com/seasky/projectplan/application/command/projectplan/ProjectPlanSvrImpl.java
+++ b/ServiceSite/src/main/java/com/seasky/projectplan/application/command/projectplan/ProjectPlanSvrImpl.java
@@ -22,6 +22,7 @@ import com.seasky.micro.basedata.dto.OrganizationDTO;
 import com.seasky.micro.basedata.dto.RoleIdsAndOrganizationRequestDTO;
 import com.seasky.micro.basedata.dto.UserDTO;
 import com.seasky.microflowapi.api.IFlow;
+import com.seasky.microflowapi.dto.CommitProcessCmd;
 import com.seasky.projectplan.application.command.assembler.ProjectPlanAssembler;
 import com.seasky.projectplan.application.command.attachment.AttachmentSvr;
 import com.seasky.projectplan.domain.aggregate.baseConfig.BaseConfigRepository;
@@ -874,8 +875,11 @@ public class ProjectPlanSvrImpl implements ProjectPlanSvr {
 
 
         List<String> userCode = getAuditCodeByInfo(cmd.getNodeIds().get(0), cmd.getId());
+        CommitProcessCmd commitProcessCmd=new CommitProcessCmd();
+        commitProcessCmd.setUserCode(userCode);
+        commitProcessCmd.setFlowSubmitCmd(null);
         //璋冪敤娴佺▼鐨勫井鏈嶅姟鎻愪氦
-        flowSvr.submitFLow(projectPlanBaseAgg.getProcessId().toString(), null, cmd.getRemake(), userCode);
+        flowSvr.submitFLow(projectPlanBaseAgg.getProcessId().toString(), null, cmd.getRemake(), commitProcessCmd);
         //鑾峰彇閫€鍥炲悗鐨勭姸鎬�
         String stateLabel = flowSvr.getStateLabelByProcessId(projectPlanBaseAgg.getProcessId().toString());
         //鍥炲啓
@@ -897,8 +901,11 @@ public class ProjectPlanSvrImpl implements ProjectPlanSvr {
         ProjectPlanBaseAgg projectPlanBaseAgg = infoRepository.queryPlanBookProcessId(cmd.getId());
 
         List<String> userCode = getAuditCodeByInfo(cmd.getNodeIds().get(0), cmd.getId());
+        CommitProcessCmd commitProcessCmd=new CommitProcessCmd();
+        commitProcessCmd.setUserCode(userCode);
+        commitProcessCmd.setFlowSubmitCmd(null);
         //璋冪敤娴佺▼鐨勫井鏈嶅姟鍥為€€
-        flowSvr.submitFLow(projectPlanBaseAgg.getProcessId().toString(), cmd.getNodeIds().get(0), cmd.getRemake(), userCode);
+        flowSvr.submitFLow(projectPlanBaseAgg.getProcessId().toString(), cmd.getNodeIds().get(0), cmd.getRemake(), commitProcessCmd);
         //鑾峰彇閫€鍥炲悗鐨勭姸鎬�
         String stateLabel = flowSvr.getStateLabelByProcessId(projectPlanBaseAgg.getProcessId().toString());
         //鍥炲啓
diff --git a/ServiceSite/src/main/java/com/seasky/projectplan/domain/service/FlowSvr.java b/ServiceSite/src/main/java/com/seasky/projectplan/domain/service/FlowSvr.java
index 803128421..f2975ae81 100644
--- a/ServiceSite/src/main/java/com/seasky/projectplan/domain/service/FlowSvr.java
+++ b/ServiceSite/src/main/java/com/seasky/projectplan/domain/service/FlowSvr.java
@@ -1,5 +1,6 @@
 package com.seasky.projectplan.domain.service;
 
+import com.seasky.microflowapi.dto.CommitProcessCmd;
 import com.seasky.microflowapi.dto.FlowCanShowOut;
 
 import java.util.List;
@@ -16,7 +17,21 @@ public interface FlowSvr {
      *
      * @return {@link Long}
      */
-    String submitFLow(String processId, String nodeId, String remake, List<String> userCodeList);
+    String submitFLow(String processId, String nodeId, String remake, CommitProcessCmd commitProcessCmd);
+
+    /**
+     * 鍥為€€娴佺▼
+     *
+     * @return {@link Long}
+     */
+    String backFlow(Long id, String activityId, String note, CommitProcessCmd commitProcessCmd);
+
+    /**
+     * 鎾ゅ洖娴佺▼
+     *
+     * @return {@link Long}
+     */
+    String recallFlow(Long id, String activityId, String note, CommitProcessCmd commitProcessCmd);
 
     /**
      * 閲嶆柊璋冪敤娴�
@@ -37,20 +52,6 @@ public interface FlowSvr {
      */
     String getStateLabelByProcessId(String processId);
 
-    /**
-     * 鍥為€€娴佺▼
-     *
-     * @return {@link Long}
-     */
-    String backFlow(Long id, String activityId, String note, List<String> userCodeList);
-
-    /**
-     * 鎾ゅ洖娴佺▼
-     *
-     * @return {@link Long}
-     */
-    String recallFlow(Long id, String activityId, String note, List<String> userCodeList);
-
     /**
      * 鐢虫姤涔﹀惎鍔ㄦ祦绋�
      *
diff --git a/ServiceSite/src/main/java/com/seasky/projectplan/domain/service/FlowSvrImpl.java b/ServiceSite/src/main/java/com/seasky/projectplan/domain/service/FlowSvrImpl.java
index 55cca50cf..806634015 100644
--- a/ServiceSite/src/main/java/com/seasky/projectplan/domain/service/FlowSvrImpl.java
+++ b/ServiceSite/src/main/java/com/seasky/projectplan/domain/service/FlowSvrImpl.java
@@ -4,6 +4,7 @@ import com.seasky.core.common.Error;
 import com.seasky.core.common.ResponseCode;
 import com.seasky.core.common.Result;
 import com.seasky.core.exception.DataAccessException;
+import com.seasky.microflowapi.dto.CommitProcessCmd;
 import com.seasky.microflowapi.dto.FlowCanShowOut;
 import com.seasky.projectplan.infrastructure.rpc.FlowRpc;
 import org.springframework.beans.factory.annotation.Autowired;
@@ -23,8 +24,8 @@ public class FlowSvrImpl implements FlowSvr {
     FlowRpc flowRpc;
 
     @Override
-    public String submitFLow(String processId, String nodeId, String remake, List<String> userCodeList) {
-        return flowRpc.submitFLow(processId, nodeId, remake, userCodeList);
+    public String submitFLow(String processId, String nodeId, String remake, CommitProcessCmd commitProcessCmd) {
+        return flowRpc.submitFLow(processId, nodeId, remake, commitProcessCmd);
     }
     @Override
     public String reCallFLow(String processId, String nodeId, String remake, List<String> userCodeList) {
@@ -46,22 +47,22 @@ public class FlowSvrImpl implements FlowSvr {
      * @return {@link String}
      */
     @Override
-    public String backFlow(Long id, String activityId, String note, List<String> userCodeList) {
-        return flowRpc.backFlow(id, activityId, note, userCodeList);
+    public String backFlow(Long id, String activityId, String note, CommitProcessCmd commitProcessCmd) {
+        return flowRpc.backFlow(id, activityId, note, commitProcessCmd);
     }
 
     /**
      * 鍥炴挙
      *
-     * @param id           id
-     * @param activityId   娲诲姩id
-     * @param note         璇锋敞鎰�
-     * @param userCodeList 鐢ㄦ埛浠g爜鍒楄〃
+     * @param id               id
+     * @param activityId       娲诲姩id
+     * @param note             璇锋敞鎰�
+     * @param commitProcessCmd 鎻愪氦杩涚▼cmd
      * @return {@link String}
      */
     @Override
-    public String recallFlow(Long id, String activityId, String note, List<String> userCodeList) {
-        return flowRpc.recallFlow(id, activityId, note, userCodeList);
+    public String recallFlow(Long id, String activityId, String note, CommitProcessCmd commitProcessCmd) {
+        return flowRpc.recallFlow(id, activityId, note, commitProcessCmd);
     }
 
     @Override
diff --git a/ServiceSite/src/main/java/com/seasky/projectplan/infrastructure/reader/projectplan/ProjectPlanQueryServiceImpl.java b/ServiceSite/src/main/java/com/seasky/projectplan/infrastructure/reader/projectplan/ProjectPlanQueryServiceImpl.java
index 8db393a92..661ab1afc 100644
--- a/ServiceSite/src/main/java/com/seasky/projectplan/infrastructure/reader/projectplan/ProjectPlanQueryServiceImpl.java
+++ b/ServiceSite/src/main/java/com/seasky/projectplan/infrastructure/reader/projectplan/ProjectPlanQueryServiceImpl.java
@@ -18,12 +18,15 @@ import com.seasky.core.common.ResponseCode;
 import com.seasky.core.common.Result;
 import com.seasky.core.ddd.utils.MapperUtils;
 import com.seasky.core.exception.DataAccessException;
+import com.seasky.core.util.CustomLogger;
 import com.seasky.core.util.ExceptionUtil;
+import com.seasky.core.util.Logger;
 import com.seasky.micro.basedata.api.IUser;
 import com.seasky.micro.basedata.dto.OrganizationDTO;
 import com.seasky.micro.basedata.dto.RoleIdsAndOrganizationRequestDTO;
 import com.seasky.micro.basedata.dto.UserDTO;
 import com.seasky.microflowapi.api.IFlow;
+import com.seasky.microflowapi.dto.CommitProcessCmd;
 import com.seasky.microflowapi.dto.FlowCanShowOut;
 import com.seasky.projectplan.application.query.projectplan.ProjectPlanQueryService;
 import com.seasky.projectplan.domain.aggregate.common.AuditEnum;
@@ -2045,8 +2048,11 @@ public class ProjectPlanQueryServiceImpl extends AbstractService<ProjectPlanBook
             );
         }
         ExceptionUtil.isTrue(!isShowSubmit, "褰撳墠鐧诲綍浜烘病鏈夋潈闄愭搷鍋氭娴佺▼");*/
+        CommitProcessCmd commitProcessCmd=new CommitProcessCmd();
+        commitProcessCmd.setUserCode(getCodeList(actionFlowCmd.getNodeIds().get(0), targetPlanPos.get(0).getId(), actionFlowCmd.getId()));
+        commitProcessCmd.setFlowSubmitCmd(null);
         flowRpc.submitFLow
-                (targetPlanPos.get(0).getProcessId().toString(), null, actionFlowCmd.getRemake(), getCodeList(actionFlowCmd.getNodeIds().get(0), targetPlanPos.get(0).getId()));
+                (targetPlanPos.get(0).getProcessId().toString(), null, actionFlowCmd.getRemake(), commitProcessCmd);
         String stateLabelByProcessId = flowRpc.getStateLabelByProcessId(targetPlanPos.get(0).getProcessId().toString());
         //璁剧疆娴佺▼鐘舵€�
         targetPlanPos.get(0).setState(stateLabelByProcessId);
@@ -2097,8 +2103,11 @@ public class ProjectPlanQueryServiceImpl extends AbstractService<ProjectPlanBook
             );
         }*/
         //璋冪敤RPC
+        CommitProcessCmd commitProcessCmd=new CommitProcessCmd();
+        commitProcessCmd.setUserCode(getCodeList(actionFlowCmd.getNodeIds().get(0), targetPlanPos.get(0).getId(), actionFlowCmd.getId()));
+        commitProcessCmd.setFlowSubmitCmd(null);
         flowRpc.backFlow
-                (targetPlanPos.get(0).getProcessId(), actionFlowCmd.getNodeIds().get(0), actionFlowCmd.getRemake(), getCodeList(actionFlowCmd.getNodeIds().get(0), targetPlanPos.get(0).getId()));
+                (targetPlanPos.get(0).getProcessId(), actionFlowCmd.getNodeIds().get(0), actionFlowCmd.getRemake(), commitProcessCmd);
 
         //鑾峰彇娴佺▼鐘舵€�
         String stateLabelByProcessId = flowRpc.getStateLabelByProcessId(targetPlanPos.get(0).getProcessId().toString());
@@ -2120,6 +2129,7 @@ public class ProjectPlanQueryServiceImpl extends AbstractService<ProjectPlanBook
     /**
      * 鍥炴挙
      */
+    private static final Logger log = CustomLogger.getLogger(ProjectPlanQueryServiceImpl.class);
     @Override
     public void recallTarget(ActionFlowCmd actionFlowCmd) {
         try {
@@ -2127,21 +2137,18 @@ public class ProjectPlanQueryServiceImpl extends AbstractService<ProjectPlanBook
             targetPlan.put("parentId", actionFlowCmd.getId());
             targetPlan.put("type", actionFlowCmd.getType());
             List<TargetPlanPo> targetPlanPos = targetPlanMapper.selectByMap(targetPlan);
-            if (ObjectUtils.isEmpty(targetPlanPos) || targetPlanPos.size() == 0) {
-                throw new DataAccessException(
-                        Error.builder()
-                                .responseCode(ResponseCode.DATA_VERIFY_NULL_POINTER)
-                                .message("鐩爣璁″垝涓嶅瓨鍦�")
-                                .build()
-                );
-            }
+            ExceptionUtil.isNull(targetPlanPos, "鐩爣璁″垝涓嶅瓨鍦�");
             String nodeId = "sid-D4784941-DBF9-4BA0-863F-6BC7515878C3";
 
-            List<String> userCode = getCodeList(nodeId, targetPlanPos.get(0).getId());
+            List<String> userCode = getCodeList(nodeId, targetPlanPos.get(0).getId(), actionFlowCmd.getId());
+            CommitProcessCmd commitProcessCmd=new CommitProcessCmd();
+            commitProcessCmd.setUserCode(userCode);
+            commitProcessCmd.setFlowSubmitCmd(null);
             //璋冪敤娴佺▼鐨勫井鏈嶅姟鍥為€€
-            flowSvr.reCallFLow(targetPlanPos.get(0).getProcessId().toString(), nodeId, "鍒跺崟浜鸿嚜琛屾挙鍥�", userCode);
+            flowSvr.recallFlow(targetPlanPos.get(0).getProcessId(), nodeId, "鍒跺崟浜鸿嚜琛屾挙鍥�", commitProcessCmd);
             //鑾峰彇閫€鍥炲悗鐨勭姸鎬�
             String stateLabel = flowSvr.getStateLabelByProcessId(targetPlanPos.get(0).getProcessId().toString());
+            log.info("杈撳嚭鍥炴挙鍚庣殑鐘舵€�:{}", stateLabel);
             //鍥炲啓
             targetPlanPos.get(0).setState(stateLabel);
             targetPlanMapper.updateById(targetPlanPos.get(0));
@@ -2262,8 +2269,10 @@ public class ProjectPlanQueryServiceImpl extends AbstractService<ProjectPlanBook
      *
      * @return {@link List}<{@link String}>
      */
-    public List<String> getCodeList(String nextNodeId, Long id) {
-//寰呮彁浜�
+    public List<String> getCodeList(String nextNodeId, Long id, Long projectBookId) {
+        ProjectPlanBookPo projectPlanBookPo = projectPlanBookMapper.selectById(projectBookId);
+        ExceptionUtil.isNull(projectPlanBookPo, "鑾峰彇鍒颁簡鏃犳晥鐨勭敵鎶ュ崟Id");
+        //寰呮彁浜�
         List<String> userCodeList = new ArrayList<>();
         if ("sid-D4784941-DBF9-4BA0-863F-6BC7515878C3".equals(nextNodeId)) {
             //椤圭洰璐熻矗浜哄彂璧�
@@ -2273,6 +2282,22 @@ public class ProjectPlanQueryServiceImpl extends AbstractService<ProjectPlanBook
             Result<UserDTO> userList = iUser.getUser(userDTO);
             String userCode = userList.getData().get(0).getCode();
             userCodeList.add(userCode);
+        }else if ("sid-5FE98FD5-F3D6-4F80-8C7B-ED3434396B0C".equals(nextNodeId)) {
+            //閮ㄩ棬棰嗗瀹℃牳
+            RoleIdsAndOrganizationRequestDTO roleIdsAndOrganizationRequestDTO = RoleIdsAndOrganizationRequestDTO.builder().build();
+            List<Long> roleIdList = new ArrayList<>(1);
+            if (projectPlanBookPo.getDepartmentCode() == null) {
+                throw new DataAccessException(new Error(ResponseCode.DATA_VERIFY_EXCEPTION, null, "寮傚父:鏈幏鍙栧埌缂栧埗涔︽墍灞炵殑閮ㄩ棬", ""));
+            }
+            //閮ㄩ棬棰嗗roleId
+            roleIdList.add(new Long("1410486235709300738"));
+            roleIdsAndOrganizationRequestDTO.setRoleIds(roleIdList);
+            roleIdsAndOrganizationRequestDTO.setOrganizationCode(projectPlanBookPo.getDepartmentCode());
+            Result<UserDTO> user = iUser.listByRoleIdsAndOrganization(roleIdsAndOrganizationRequestDTO);
+            for (UserDTO userDTO : user.getData()) {
+                String userCode = userDTO.getCode();
+                userCodeList.add(userCode);
+            }
         } else if ("sid-9EE30D6C-0292-46EC-9DDB-E1CB3A08C66E".equals(nextNodeId)) {
             //璐㈠姟澶勭‘璁�
             RoleIdsAndOrganizationRequestDTO roleIdsAndOrganizationRequestDTO = RoleIdsAndOrganizationRequestDTO.builder().build();
diff --git a/ServiceSite/src/main/java/com/seasky/projectplan/infrastructure/rpc/FlowRpc.java b/ServiceSite/src/main/java/com/seasky/projectplan/infrastructure/rpc/FlowRpc.java
index b43ad6f26..8be7b327f 100644
--- a/ServiceSite/src/main/java/com/seasky/projectplan/infrastructure/rpc/FlowRpc.java
+++ b/ServiceSite/src/main/java/com/seasky/projectplan/infrastructure/rpc/FlowRpc.java
@@ -1,6 +1,7 @@
 package com.seasky.projectplan.infrastructure.rpc;
 
 import com.seasky.core.common.Result;
+import com.seasky.microflowapi.dto.CommitProcessCmd;
 import com.seasky.microflowapi.dto.FlowCanShowOut;
 
 import java.util.List;
@@ -18,7 +19,7 @@ public interface FlowRpc {
      *
      * @return {@link Long}
      */
-    String submitFLow(String processId, String nodeId, String remake, List<String> userCodeList);
+    String submitFLow(String processId, String nodeId, String remake, CommitProcessCmd commitProcessCmd);
 
     String reCallFLow(String processId, String nodeId, String remake, List<String> userCodeList);
 
@@ -35,14 +36,14 @@ public interface FlowRpc {
      *
      * @return {@link Long}
      */
-    String backFlow(Long id, String activityId, String note, List<String> userCodeList);
+    String backFlow(Long id, String activityId, String note, CommitProcessCmd commitProcessCmd);
 
     /**
      * 鎾ゅ洖娴佺▼
      *
      * @return {@link Long}
      */
-    String recallFlow(Long id, String activityId, String note, List<String> userCodeList);
+    String recallFlow(Long id, String activityId, String note, CommitProcessCmd commitProcessCmd);
 
     /**
      * 鐢虫姤涔﹀惎鍔ㄦ祦绋�
diff --git a/ServiceSite/src/main/java/com/seasky/projectplan/infrastructure/rpc/FlowRpcImpl.java b/ServiceSite/src/main/java/com/seasky/projectplan/infrastructure/rpc/FlowRpcImpl.java
index a713f086e..23ad47053 100644
--- a/ServiceSite/src/main/java/com/seasky/projectplan/infrastructure/rpc/FlowRpcImpl.java
+++ b/ServiceSite/src/main/java/com/seasky/projectplan/infrastructure/rpc/FlowRpcImpl.java
@@ -6,6 +6,7 @@ import com.seasky.core.common.Result;
 import com.seasky.core.exception.DataAccessException;
 import com.seasky.micro.basedata.api.IUser;
 import com.seasky.microflowapi.api.IFlow;
+import com.seasky.microflowapi.dto.CommitProcessCmd;
 import com.seasky.microflowapi.dto.FlowCanShowOut;
 import org.springframework.stereotype.Repository;
 import org.springframework.util.StringUtils;
@@ -38,8 +39,8 @@ public class FlowRpcImpl implements FlowRpc {
      * @return {@link String}
      */
     @Override
-    public String submitFLow(String processId, String nodeId, String remake, List<String> userCodeList) {
-        Result<Integer> integerResult = flow.commitProcess(processId, nodeId, remake, userCodeList);
+    public String submitFLow(String processId, String nodeId, String remake, CommitProcessCmd commitProcessCmd) {
+        Result<Integer> integerResult = flow.commitProcess(processId, nodeId, remake, commitProcessCmd);
         if (!ResponseCode.SUCCESS.value().equals(integerResult.getCode())) {
             throw new DataAccessException(new Error(ResponseCode.BUNISESS_EXCEPTION, null, "娴佺▼绉诲姩澶辫触", ""));
         }
@@ -72,36 +73,35 @@ public class FlowRpcImpl implements FlowRpc {
     }
 
     /**
+     * 鍥炴祦
      * 鍥炴粴
      *
-     * @param id           id
-     * @param activityId   娲诲姩id
-     * @param note         璇锋敞鎰�
-     * @param userCodeList 鐢ㄦ埛浠g爜鍒楄〃
+     * @param id               id
+     * @param activityId       娲诲姩id
+     * @param note             璇锋敞鎰�
+     * @param commitProcessCmd 鎻愪氦杩涚▼cmd
      * @return {@link String}
      */
     @Override
-    public String backFlow(Long id, String activityId, String note, List<String> userCodeList) {
+    public String backFlow(Long id, String activityId, String note, CommitProcessCmd commitProcessCmd) {
         String a = id.toString(), b = activityId, c = note;
-        List<String> d = userCodeList;
-        String s = flow.commitProcess(a, b, c, d).toString();
+        String s = flow.commitProcess(a, b, c, commitProcessCmd).toString();
         return flow.getStateLabelByProcessId(Long.toString(id)).toString();
     }
 
     /**
      * 鍥炴挙
      *
-     * @param id           id
-     * @param activityId   娲诲姩id
-     * @param note         璇锋敞鎰�
-     * @param userCodeList 鐢ㄦ埛浠g爜鍒楄〃
+     * @param id               id
+     * @param activityId       娲诲姩id
+     * @param note             璇锋敞鎰�
+     * @param commitProcessCmd 鎻愪氦杩涚▼cmd
      * @return {@link String}
      */
     @Override
-    public String recallFlow(Long id, String activityId, String note, List<String> userCodeList) {
+    public String recallFlow(Long id, String activityId, String note, CommitProcessCmd commitProcessCmd) {
         String a = id.toString(), b = activityId, c = note;
-        List<String> d = userCodeList;
-        String s = flow.commitProcess(a, b, c, d).toString();
+        String s = flow.commitProcess(a, b, c, commitProcessCmd).toString();
         return flow.getStateLabelByProcessId(Long.toString(id)).toString();
     }
 
-- 
GitLab