From 704ce3e8e648592e8b5c73399603d9831fd952cb Mon Sep 17 00:00:00 2001
From: mrzhssss <pro6@qq.com>
Date: 星期一, 28 十一月 2022 17:32:37 +0800
Subject: [PATCH] #

---
 src/main/java/com/zy/asrs/service/impl/MainServiceImpl.java |   23 ++++++++---
 src/main/webapp/views/index.html                            |    2 
 src/main/webapp/static/js/console.map.js                    |   16 ++++----
 src/main/webapp/views/monitor/data/map.json                 |    2 
 src/main/java/com/zy/common/model/LocTypeDto.java           |   17 ++++----
 src/main/resources/application.yml                          |   12 +++---
 6 files changed, 41 insertions(+), 31 deletions(-)

diff --git a/src/main/java/com/zy/asrs/service/impl/MainServiceImpl.java b/src/main/java/com/zy/asrs/service/impl/MainServiceImpl.java
index 72d06fc..531405e 100644
--- a/src/main/java/com/zy/asrs/service/impl/MainServiceImpl.java
+++ b/src/main/java/com/zy/asrs/service/impl/MainServiceImpl.java
@@ -106,6 +106,9 @@
                     continue;
                 }
                 String barcode = barcodeThread.getBarcode();
+
+                barcode = "80011105";
+
                 if (!Cools.isEmpty(barcode)) {
                     log.info("{}鍙锋潯鐮佹壂鎻忓櫒妫�娴嬫潯鐮佷俊鎭細{}", inSta.getBarcode(), barcode);
                     if ("NG".endsWith(barcode) || "NoRead".equals(barcode)) {
@@ -116,6 +119,7 @@
                 }
 
                 // 鑾峰彇鍏ュ簱绔欎俊鎭�
+//                SiemensDevpThread devpThread = (SiemensDevpThread) SlaveConnection.get(SlaveType.Devp, devp.getId());
                 SiemensDevpThread devpThread = (SiemensDevpThread) SlaveConnection.get(SlaveType.Devp, devp.getId());
                 StaProtocol staProtocol = devpThread.getStation().get(inSta.getStaNo());
                 if (staProtocol == null) {
@@ -126,14 +130,16 @@
 
                 // 鍏ュ嚭搴撴ā寮忓垽鏂�
 //                if ( inSta.getStaNo()==203 && devpThread.ioModeOf2F != IoModeType.PAKIN_MODE) { continue; }
-                if (inSta.getStaNo() == 203 && devpThread.ioModeOf2F == IoModeType.PAKOUT_MODE) {
-                    continue;
-                }
+//                if (inSta.getStaNo() == 203 && devpThread.ioModeOf2F == IoModeType.PAKOUT_MODE) {
+//                    continue;
+//                }
 
                 // 鍒ゆ柇鏄惁婊¤冻鍏ュ簱鏉′欢
-                if (staProtocol.isAutoing() && staProtocol.isLoading()
+                if (staProtocol.isAutoing()
+                        && staProtocol.isLoading()
                         && staProtocol.isInEnable()
-                        && !staProtocol.isEmptyMk() && (staProtocol.getWorkNo() == 0 || staProtocol.getWorkNo() > 9990)
+                        && !staProtocol.isEmptyMk()
+                        && (staProtocol.getWorkNo() == 0 || staProtocol.getWorkNo() > 9990)
                         && staProtocol.isPakMk()) {// && !Cools.isEmpty(barcode)) {
 
 //                    if(Cools.isEmpty(barcode) || "NG".endsWith(barcode) || "NoRead".equals(barcode)) {
@@ -532,8 +538,11 @@
 //            }
 
             // 鍙湁褰撳爢鍨涙満绌洪棽 骞朵笖 鏃犱换鍔℃椂鎵嶇户缁墽琛�
-            if (crnProtocol.getStatusType() == CrnStatusType.IDLE && crnProtocol.getTaskNo() == 0 && crnProtocol.getModeType() == CrnModeType.AUTO
-                    && crnProtocol.getLoaded() == 0 && crnProtocol.getForkPos() == 0) {
+            if (crnProtocol.getStatusType() == CrnStatusType.IDLE
+                    && crnProtocol.getTaskNo() == 0
+                    && crnProtocol.getModeType() == CrnModeType.AUTO
+                    && crnProtocol.getLoaded() == 0
+                    && crnProtocol.getForkPos() == 0) {
                 // 濡傛灉鏈�杩戜竴娆℃槸鍏ュ簱妯″紡
                 if (crnProtocol.getLastIo().equals("I")) {
                     if (basCrnp.getInEnable().equals("Y")) {
diff --git a/src/main/java/com/zy/common/model/LocTypeDto.java b/src/main/java/com/zy/common/model/LocTypeDto.java
index 4cb4b14..20382a2 100644
--- a/src/main/java/com/zy/common/model/LocTypeDto.java
+++ b/src/main/java/com/zy/common/model/LocTypeDto.java
@@ -29,14 +29,15 @@
     }
 
     public LocTypeDto(StaProtocol staProtocol) {
-        if (staProtocol.isHigh() == staProtocol.isLow()) {
-            throw new CoolException("plc楂樹綆妫�娴嬪紓甯�");
-        }
-        if (staProtocol.isLow()) {
-            this.locType1 = 1; // 浣庡簱浣�
-        } else {
-            this.locType1 = 2; // 楂樺簱浣�
-        }
+//        if (staProtocol.isHigh() == staProtocol.isLow()) {
+//            throw new CoolException("plc楂樹綆妫�娴嬪紓甯�");
+//        }
+//        if (staProtocol.isLow()) {
+//            this.locType1 = 1; // 浣庡簱浣�
+//        } else {
+//            this.locType1 = 2; // 楂樺簱浣�
+//        }
+        this.locType1 = 1;
     }
 
     /**
diff --git a/src/main/resources/application.yml b/src/main/resources/application.yml
index 0c9b60b..507e9dc 100644
--- a/src/main/resources/application.yml
+++ b/src/main/resources/application.yml
@@ -149,17 +149,17 @@
     slot: 0
     # 鍏ュ簱鍙�1
     inSta[0]:
-      staNo: 015
+      staNo: 15
       barcode: ${wcs-slave.barcode[0].id}
     # 绌烘澘鍏ュ簱鍙�1
     emptyInSta[0]:
-      staNo: 012
+      staNo: 12
     # 鍑哄簱鍙�1
     outSta[0]:
-      staNo: 011
+      staNo: 11
     # 鎷f枡鍏ュ簱鍙�1
     pickSta[0]:
-      staNo: 011
+      staNo: 11
       barcode: ${wcs-slave.barcode[0].id}
 
   # 鏉$爜鎵弿浠�
@@ -173,11 +173,11 @@
     ip: 10.10.10.201
     port: 5005
     devpPlcId: ${wcs-slave.devp[0].id}
-    staArr: 015
+    staArr: 15
   # LED2
   led[1]:
     id: 2
     ip: 10.10.10.202
     port: 5005
     devpPlcId: ${wcs-slave.devp[0].id}
-    staArr: 011
\ No newline at end of file
+    staArr: 11
\ No newline at end of file
diff --git a/src/main/webapp/static/js/console.map.js b/src/main/webapp/static/js/console.map.js
index c357061..da770d3 100644
--- a/src/main/webapp/static/js/console.map.js
+++ b/src/main/webapp/static/js/console.map.js
@@ -170,8 +170,8 @@
     }],
     "crns": [{
         "type": "crane",
-        "id": "crn-4",
-        "text": "4",
+        "id": "crn-1",
+        "text": "1",
         "top": 252,
         "left": 501,
         "width": 93,
@@ -186,8 +186,8 @@
         "height": 2
     }, {
         "type": "crane",
-        "id": "crn-3",
-        "text": "3",
+        "id": "crn-2",
+        "text": "2",
         "top": 367,
         "left": 512,
         "width": 93,
@@ -202,8 +202,8 @@
         "height": 2
     }, {
         "type": "crane",
-        "id": "crn-2",
-        "text": "2",
+        "id": "crn-3",
+        "text": "3",
         "top": 481,
         "left": 501,
         "width": 93,
@@ -226,8 +226,8 @@
         "height": 2
     }, {
         "type": "crane",
-        "id": "crn-1",
-        "text": "1",
+        "id": "crn-4",
+        "text": "4",
         "top": 595,
         "left": 501,
         "width": 93,
diff --git a/src/main/webapp/views/index.html b/src/main/webapp/views/index.html
index 6b47357..2d8640c 100644
--- a/src/main/webapp/views/index.html
+++ b/src/main/webapp/views/index.html
@@ -26,7 +26,7 @@
 <!-- 涓讳綋鍐呭 -->
 <iframe id="content" src="console.html"></iframe>
 <footer class="footer">
-    Copyright 漏 2015 All Rights Reserved. <a href="http://www.zoneyung.com" target="_blank">娴欐睙涓壃绔嬪簱鎶�鏈湁闄愬叕鍙�</a>  淇濈暀鎵�鏈夋潈鍒�
+    Copyright 漏 2015 All Rights Reserved. <a href="https://www.superton.cn/" target="_blank">娴欐睙閫熻吘鐢靛瓙鎶�鏈湁闄愬叕鍙�</a>  淇濈暀鎵�鏈夋潈鍒�
 </footer>
 </body>
 <script>
diff --git a/src/main/webapp/views/monitor/data/map.json b/src/main/webapp/views/monitor/data/map.json
index a2aa8d4..a037982 100644
--- a/src/main/webapp/views/monitor/data/map.json
+++ b/src/main/webapp/views/monitor/data/map.json
@@ -72,4 +72,4 @@
       }
     }
   ]
-};
\ No newline at end of file
+}
\ No newline at end of file

--
Gitblit v1.9.1