From 70c104c001de0c586b0d468a30729a9a944560ef Mon Sep 17 00:00:00 2001
From: cpT <1@123>
Date: 星期四, 29 一月 2026 16:42:23 +0800
Subject: [PATCH] #

---
 src/main/java/com/zy/core/utils/DualCrnOperateProcessUtils.java |   51 ++++++++++++++++++++++++++++++++++++++++++++-------
 1 files changed, 44 insertions(+), 7 deletions(-)

diff --git a/src/main/java/com/zy/core/utils/DualCrnOperateProcessUtils.java b/src/main/java/com/zy/core/utils/DualCrnOperateProcessUtils.java
index f763f44..c0b1e29 100644
--- a/src/main/java/com/zy/core/utils/DualCrnOperateProcessUtils.java
+++ b/src/main/java/com/zy/core/utils/DualCrnOperateProcessUtils.java
@@ -404,7 +404,25 @@
             return false;
         }
 
+        List<StationObjModel> enableUseStationList = new ArrayList<>();
         for (StationObjModel stationObjModel : outStationList) {
+            if (!stationObjModel.getStationId().equals(wrkMast.getSourceStaNo())) {
+                continue;
+            }
+
+            if(stationObjModel.getDualCrnExecuteStation().equals(station)) {
+                enableUseStationList.add(stationObjModel);
+            }
+
+            StationObjModel dualCrnSlaveStation = stationObjModel.getDualCrnSlaveStation();
+            if(dualCrnSlaveStation != null) {
+                if (dualCrnSlaveStation.getDualCrnExecuteStation().equals(station)) {
+                    enableUseStationList.add(stationObjModel);
+                }
+            }
+        }
+
+        for (StationObjModel stationObjModel : enableUseStationList) {
             StationThread stationThread = (StationThread) SlaveConnection.get(SlaveType.Devp, stationObjModel.getDeviceNo());
             if (stationThread == null) {
                 continue;
@@ -608,15 +626,34 @@
             } else if (wrkMast.getWrkSts() == WrkStsType.OUTBOUND_RUN.sts) {
                 updateWrkSts = WrkStsType.OUTBOUND_RUN_COMPLETE.sts;
                 notifyUtils.notify(String.valueOf(SlaveType.DualCrn), basDualCrnp.getCrnNo(), String.valueOf(wrkMast.getWrkNo()), wrkMast.getWmsWrkNo(), NotifyMsgType.DUAL_CRN_OUT_TASK_COMPLETE, null);
-                
+
+                List<StationObjModel> outStationList = basDualCrnp.getOutStationList$();
+                if(outStationList.isEmpty()){
+                    News.info("鍙屽伐浣嶅爢鍨涙満:{} 鍑哄簱绔欑偣鏈缃�", basDualCrnp.getCrnNo());
+                    return;
+                }
+
+                StationObjModel outStationObjModel = null;
+                for (StationObjModel stationObjModel : outStationList) {
+                    if (stationObjModel.getStationId().equals(wrkMast.getSourceStaNo())) {
+                        outStationObjModel = stationObjModel;
+                        break;
+                    }
+                }
+
+                if (outStationObjModel == null) {
+                    News.info("鍙屽伐浣嶅爢鍨涙満:{} 鏈壘鍒板尮閰嶇殑浠诲姟鍑哄簱绔�", basDualCrnp.getCrnNo());
+                    return;
+                }
+
+                if (station == 1) {
+                    redisUtil.set(RedisKeyType.DUAL_CRN_OUT_TASK_COMPLETE_STATION_INFO.key + wrkMast.getWrkNo(), JSON.toJSONString(outStationObjModel, SerializerFeature.DisableCircularReferenceDetect), 60 * 60 * 24);
+                }else {
+                    redisUtil.set(RedisKeyType.DUAL_CRN_OUT_TASK_COMPLETE_STATION_INFO.key + wrkMast.getWrkNo(), JSON.toJSONString(outStationObjModel.getDualCrnSlaveStation(), SerializerFeature.DisableCircularReferenceDetect), 60 * 60 * 24);
+                }
+
                 if(mainProcessPlugin.contains("Fake")) {
                     //鐢熸垚浠跨湡绔欑偣鏁版嵁
-                    List<StationObjModel> outStationList = basDualCrnp.getOutStationList$();
-                    if(outStationList.isEmpty()){
-                        News.info("鍙屽伐浣嶅爢鍨涙満:{} 鍑哄簱绔欑偣鏈缃�", basDualCrnp.getCrnNo());
-                        return;
-                    }
-
                     for (StationObjModel stationObjModel : outStationList) {
                         if (!stationObjModel.getStationId().equals(wrkMast.getSourceStaNo())) {
                             continue;

--
Gitblit v1.9.1