From 0e3cac8d5d9603cdd5ff8935e4054f0018a35ed9 Mon Sep 17 00:00:00 2001
From: wujian <14790700720@163.com>
Date: 星期日, 28 四月 2024 15:08:56 +0800
Subject: [PATCH] change model10

---
 jcdm-main/src/main/java/com/jcdm/main/plcserver/sub/OPCUaSubscription.java |   29 +++++++++++++++++++----------
 1 files changed, 19 insertions(+), 10 deletions(-)

diff --git a/jcdm-main/src/main/java/com/jcdm/main/plcserver/sub/OPCUaSubscription.java b/jcdm-main/src/main/java/com/jcdm/main/plcserver/sub/OPCUaSubscription.java
index 8eb4dd6..d8ea123 100644
--- a/jcdm-main/src/main/java/com/jcdm/main/plcserver/sub/OPCUaSubscription.java
+++ b/jcdm-main/src/main/java/com/jcdm/main/plcserver/sub/OPCUaSubscription.java
@@ -149,15 +149,17 @@
                 if (CollUtil.isNotEmpty(queryOrderList)){
                     a = "1";
                 }else {
-                    a = "5";
+                    a = "4";
                 }
                 //濡傛灉鏄繑淇伐浣嶉渶瑕佷紶杈撹繑淇伐浣嶅彿
+                List<DaPassingStationCollection> daPassingStationCollections = new ArrayList<>();
+                List<RmRepairRecord> rmRepairRecords = new ArrayList<>();
                 if (OPCElement.OP465_ZZ_CODE_CHECK.equals(Node) || OPCElement.OP355_ZZ_CODE_CHECK.equals(Node)
                         || OPCElement.OP695_ZZ_CODE_CHECK.equals(Node) || OPCElement.OP755_ZZ_CODE_CHECK.equals(Node)){
                     //杩囩珯璁板綍
                     DaPassingStationCollection PassingStationCollection=new DaPassingStationCollection();
                     PassingStationCollection.setSfcCode(SNCode);
-                    List<DaPassingStationCollection> daPassingStationCollections = passingStationCollectionServiceImpl.selectDaPassingStationCollectionList(PassingStationCollection);
+                    daPassingStationCollections = passingStationCollectionServiceImpl.selectDaPassingStationCollectionList(PassingStationCollection);
                     if (CollUtil.isNotEmpty(daPassingStationCollections)){
                         DaPassingStationCollection lastOne = daPassingStationCollections.get(daPassingStationCollections.size() - 1);
                         String outRsSign = lastOne.getOutRsSign();
@@ -167,6 +169,13 @@
                             a = "2";
                         }
                     }
+                    RmRepairRecord rmRepairRecord = new RmRepairRecord();
+                    rmRepairRecord.setBoxCode(SNCode);
+                    rmRepairRecords = rmRepairRecordService.selectRmRepairRecordList(rmRepairRecord);
+                    if (CollUtil.isNotEmpty(rmRepairRecords)){
+                        a = "1";
+                    }
+
                 }
                 log.info("-----杩斿洖codeCheckFeed-----,{}",a);
 //                String a="1";
@@ -196,7 +205,7 @@
                     if (OPCElement.OP465_ZZ_CODE_CHECK.equals(Node) || OPCElement.OP355_ZZ_CODE_CHECK.equals(Node)
                     || OPCElement.OP695_ZZ_CODE_CHECK.equals(Node) || OPCElement.OP755_ZZ_CODE_CHECK.equals(Node)){
 
-                        rework(SNCode,Node);
+                        rework(SNCode,Node,daPassingStationCollections,rmRepairRecords);
                     }
                     System.out.println(entity);
 
@@ -206,7 +215,7 @@
         }
     }
 
-    private void rework(String SNCode,String Node)  throws Exception{
+    private void rework(String SNCode,String Node,List<DaPassingStationCollection> daPassingStationCollections,List<RmRepairRecord> rmRepairRecords)  throws Exception{
         BsOrderScheduling bsOrderScheduling = new BsOrderScheduling();
         bsOrderScheduling.setEngineNo(SNCode);
         List<String> allProcessCoed = new ArrayList<>();
@@ -220,15 +229,15 @@
                 allProcessCoed = bsTechnologyRouteChildInfos.stream().map(BsTechnologyRouteChildInfo::getProcessesCode).collect(Collectors.toList());
             }
         }
-        RmRepairRecord rmRepairRecord = new RmRepairRecord();
-        rmRepairRecord.setBoxCode(SNCode);
+//        RmRepairRecord rmRepairRecord = new RmRepairRecord();
+//        rmRepairRecord.setBoxCode(SNCode);
         List<ReadWriteEntity> writeList = new ArrayList<>();
-        List<RmRepairRecord> rmRepairRecords = rmRepairRecordService.selectRmRepairRecordList(rmRepairRecord);
+//        List<RmRepairRecord> rmRepairRecords = rmRepairRecordService.selectRmRepairRecordList(rmRepairRecord);
         //杩囩珯璁板綍
-        DaPassingStationCollection PassingStationCollection=new DaPassingStationCollection();
-        PassingStationCollection.setSfcCode(SNCode);
+//        DaPassingStationCollection PassingStationCollection=new DaPassingStationCollection();
+//        PassingStationCollection.setSfcCode(SNCode);
         //杩囩珯璁板綍
-        List<DaPassingStationCollection> daPassingStationCollections = passingStationCollectionServiceImpl.selectDaPassingStationCollectionList(PassingStationCollection);
+//        List<DaPassingStationCollection> daPassingStationCollections = passingStationCollectionServiceImpl.selectDaPassingStationCollectionList(PassingStationCollection);
 
         //鎵�鏈夊弽宸ュ伐浣�
         List<String> collect1 = rmRepairRecords.stream().map(RmRepairRecord::getProcessesCode).collect(Collectors.toList());

--
Gitblit v1.9.3