From a6114a739396420028f6a5397697e1e9ca90cc33 Mon Sep 17 00:00:00 2001
From: ZengTao <2773468879@qq.com>
Date: 星期三, 16 十月 2024 10:12:53 +0800
Subject: [PATCH] 版本整合05:新增opcua开关配置

---
 hangzhoumesParent/moduleService/CacheGlassModule/src/main/java/com/mes/job/CacheGlassTask.java |   72 ------------------------
 hangzhoumesParent/moduleService/CacheVerticalGlassModule/src/main/resources/application.yml    |    5 +
 hangzhoumesParent/moduleService/LoadGlassModule/src/main/resources/application.yml             |    5 +
 hangzhoumesParent/moduleService/CacheGlassModule/src/main/resources/application.yml            |    9 --
 hangzhoumesParent/moduleService/GlassStorageModule/src/main/resources/application.yml          |    3 +
 hangzhoumesParent/moduleService/UnLoadGlassModule/src/main/resources/application.yml           |   36 ++++++++++++
 6 files changed, 49 insertions(+), 81 deletions(-)

diff --git a/hangzhoumesParent/moduleService/CacheGlassModule/src/main/java/com/mes/job/CacheGlassTask.java b/hangzhoumesParent/moduleService/CacheGlassModule/src/main/java/com/mes/job/CacheGlassTask.java
index 37eb415..f16434c 100644
--- a/hangzhoumesParent/moduleService/CacheGlassModule/src/main/java/com/mes/job/CacheGlassTask.java
+++ b/hangzhoumesParent/moduleService/CacheGlassModule/src/main/java/com/mes/job/CacheGlassTask.java
@@ -806,78 +806,6 @@
         return Boolean.FALSE;
     }
 
-    /**
-     * 淇濆瓨鍑虹墖浠诲姟鐩稿叧淇℃伅
-     *
-     * @param glassInfo
-     * @param endcell
-     * @param confirmationWrodAddress
-     * @param glassId
-     * @return
-     */
-    private boolean saveOutGlassMessageBySlot(EdgStorageCageDetails glassInfo, int endcell, String confirmationWrodAddress, String glassId, Integer currentSlot) {
-        if (glassInfo != null) {
-            log.info("4銆佹坊鍔犲嚭鐗囦换鍔★紝鐜荤拑id锛歿}锛屼换鍔$被鍨嬶細{}锛岃捣濮嬩綅缃細{}锛岀粨鏉熶綅缃細{}", glassInfo.getGlassId(),
-                    2, glassInfo.getSlot(), endcell);
-            if (glassInfo.getGlassId().equals(glassId)) {
-                log.info("5銆佺洿閫氫换鍔�,灏嗙幓鐠冧俊鎭彃鍏ュ崸寮忕悊鐗囩,褰撳墠鐜荤拑淇℃伅:{}", glassInfo);
-                EdgStorageCageDetails details = new EdgStorageCageDetails();
-                //鐜荤拑淇℃伅鏇挎崲
-                String glassIdChange = queryAndChangeGlass(glassId);
-                if (StringUtils.isBlank(glassIdChange)) {
-                    BeanUtils.copyProperties(glassInfo, details);
-                } else {
-                    GlassInfo one = glassInfoService.getOne(new LambdaQueryWrapper<GlassInfo>().eq(GlassInfo::getGlassId, glassId));
-                    BeanUtils.copyProperties(glassInfo, details);
-                }
-                EdgStorageCage nearestEmpty = edgStorageCageService.selectNearestEmpty(currentSlot, Boolean.TRUE);
-                Assert.isTrue(null != nearestEmpty, "鏍煎瓙宸叉弧,鏃犳硶鎵ц鐩撮�氫换鍔�");
-                log.info("3銆佹煡璇㈠崸寮忕悊鐗囩閲岄潰鐨勭┖鏍�:{}", nearestEmpty);
-                details.setSlot(nearestEmpty.getSlot());
-                details.setState(Const.GLASS_STATE_OUT);
-                edgStorageCageDetailsService.save(details);
-                boolean taskCacheStatus = saveTaskCache(glassInfo.getGlassId(), nearestEmpty.getSlot(), endcell, Const.GLASS_CACHE_TYPE_THROUGH);
-                log.info("6銆佹坊鍔犲嚭鐗囦换鍔℃槸鍚﹀畬鎴愶細{}", taskCacheStatus);
-            } else {
-                log.info("5銆侀潪鐩撮�氫换鍔�,灏嗙幓鐠冧俊鎭彃鍏ュ崸寮忕悊鐗囩,褰撳墠鐜荤拑淇℃伅:{}", glassInfo);
-                if (endcell != currentSlot) {
-                    EdgStorageCageDetails currentGlass = edgStorageCageDetailsService.getOne(new LambdaQueryWrapper<EdgStorageCageDetails>()
-                            .eq(EdgStorageCageDetails::getState, Const.GLASS_STATE_IN)
-                            .eq(EdgStorageCageDetails::getSlot, currentSlot).eq(EdgStorageCageDetails::getWidth, glassInfo.getWidth())
-                            .eq(EdgStorageCageDetails::getHeight, glassInfo.getHeight()).eq(EdgStorageCageDetails::getThickness, glassInfo.getThickness())
-                    );
-                    if (null != currentGlass) {
-                        glassInfo = currentGlass;
-                        endcell = currentSlot;
-                    }
-                }
-                //鐜荤拑淇℃伅鏇挎崲
-                String glassIdChange = queryAndChangeGlass(glassInfo.getGlassId());
-                //澶勭悊鍦ㄥ崸鐞嗗唴鐨勭幓鐠冧俊鎭細绗煎唴鐨勬暟鎹鐞�
-                queryEdgAndChangeGlass(glassInfo.getGlassId(), glassIdChange);
-                LambdaUpdateWrapper<EdgStorageCageDetails> wrapper = new LambdaUpdateWrapper<>();
-                wrapper.eq(EdgStorageCageDetails::getGlassId, glassInfo.getGlassId()).set(EdgStorageCageDetails::getState, Const.GLASS_STATE_OUT);
-                edgStorageCageDetailsService.update(wrapper);
-                log.info("5銆佹洿鏂板嚭鐗囩幓鐠冪殑鐘舵�佷负{}", Const.GLASS_STATE_OUT);
-
-                boolean taskCacheStatus = saveTaskCache(glassInfo.getGlassId(), glassInfo.getSlot(), endcell, Const.GLASS_CACHE_TYPE_OUT);
-                log.info("6銆佹坊鍔犲嚭鐗囦换鍔℃槸鍚﹀畬鎴愶細{}", taskCacheStatus);
-            }
-            boolean glassSizeStatus = saveGlassSize(glassInfo, endcell);
-            log.info("7銆佹坊鍔犲嚭鐗囩幓鐠冨昂瀵镐俊鎭埌纾ㄨ竟鍓嶇幓鐠冭〃鏄惁瀹屾垚锛歿}", glassSizeStatus);
-            S7object.getinstance().plccontrol.writeWord(confirmationWrodAddress, 1);
-            log.info("8銆佸彂閫佺‘璁ゅ瓧宸插畬鎴�");
-            Damage damage = new Damage();
-            damage.setGlassId(glassInfo.getGlassId());
-            damage.setWorkingProcedure("鍒囧壊");
-            damage.setLine(1001);
-            damage.setType(1);
-            damage.setRemark("杩囧崸寮忕悊鐗�");
-            damageService.insertDamage(damage);
-            return Boolean.TRUE;
-        }
-        return Boolean.FALSE;
-    }
 
     /**
      * 娣诲姞鐞嗙墖绗间换鍔�
diff --git a/hangzhoumesParent/moduleService/CacheGlassModule/src/main/resources/application.yml b/hangzhoumesParent/moduleService/CacheGlassModule/src/main/resources/application.yml
index c7d8792..dee1ac9 100644
--- a/hangzhoumesParent/moduleService/CacheGlassModule/src/main/resources/application.yml
+++ b/hangzhoumesParent/moduleService/CacheGlassModule/src/main/resources/application.yml
@@ -30,12 +30,7 @@
       secondLength: 400
   sequence:
     order: false
+kangaroohy:
   milo:
-    primary: default
-    config:
-      default:
-        endpoint: opc.tcp://127.0.0.1:49320
-        security-policy: basic256sha256
-        username: zsh
-        password: 1qaz2wsx3edc4rfv
+    enabled: false
 
diff --git a/hangzhoumesParent/moduleService/CacheVerticalGlassModule/src/main/resources/application.yml b/hangzhoumesParent/moduleService/CacheVerticalGlassModule/src/main/resources/application.yml
index 8449550..a72f34b 100644
--- a/hangzhoumesParent/moduleService/CacheVerticalGlassModule/src/main/resources/application.yml
+++ b/hangzhoumesParent/moduleService/CacheVerticalGlassModule/src/main/resources/application.yml
@@ -21,4 +21,7 @@
   inCarMaxSize: 0    #杩涚墖澶ц溅鏈�澶у瓨鏀剧幓鐠冩暟閲�
   outCarMaxSize: 2     #鍑虹墖澶ц溅鏈�澶у瓨鏀剧幓鐠冩暟閲�
   glassGap: 350  #鐜荤拑闂磋窛
-  xMaxSize: 2800
\ No newline at end of file
+  xMaxSize: 2800
+kangaroohy:
+  milo:
+    enabled: false
\ No newline at end of file
diff --git a/hangzhoumesParent/moduleService/GlassStorageModule/src/main/resources/application.yml b/hangzhoumesParent/moduleService/GlassStorageModule/src/main/resources/application.yml
index d2bd76c..b707f28 100644
--- a/hangzhoumesParent/moduleService/GlassStorageModule/src/main/resources/application.yml
+++ b/hangzhoumesParent/moduleService/GlassStorageModule/src/main/resources/application.yml
@@ -14,5 +14,8 @@
   mapper-locations: classpath*:mapper/*.xml
   configuration:
     log-impl: org.apache.ibatis.logging.stdout.StdOutImpl
+kangaroohy:
+  milo:
+    enabled: false
 
 
diff --git a/hangzhoumesParent/moduleService/LoadGlassModule/src/main/resources/application.yml b/hangzhoumesParent/moduleService/LoadGlassModule/src/main/resources/application.yml
index d61e1b4..abbddf5 100644
--- a/hangzhoumesParent/moduleService/LoadGlassModule/src/main/resources/application.yml
+++ b/hangzhoumesParent/moduleService/LoadGlassModule/src/main/resources/application.yml
@@ -10,4 +10,7 @@
 mybatis-plus:
   mapper-locations: classpath*:mapper/*.xml
   configuration:
-    log-impl: org.apache.ibatis.logging.stdout.StdOutImpl
\ No newline at end of file
+    log-impl: org.apache.ibatis.logging.stdout.StdOutImpl
+kangaroohy:
+  milo:
+    enabled: false
\ No newline at end of file
diff --git a/hangzhoumesParent/moduleService/UnLoadGlassModule/src/main/resources/application.yml b/hangzhoumesParent/moduleService/UnLoadGlassModule/src/main/resources/application.yml
new file mode 100644
index 0000000..5873f82
--- /dev/null
+++ b/hangzhoumesParent/moduleService/UnLoadGlassModule/src/main/resources/application.yml
@@ -0,0 +1,36 @@
+server:
+  port: 8085
+
+spring:
+  profiles:
+    active: cz
+  application:
+    name: unLoadGlass
+  liquibase:
+    enabled: false
+  task:
+    scheduling:
+      pool:
+        size: 10
+      thread-name-prefix: task-unLoad
+
+
+mybatis-plus:
+  mapper-locations: classpath*:mapper/*.xml
+#  configuration:
+#    log-impl: org.apache.ibatis.logging.stdout.StdOutImpl
+
+mes:
+  maxWidth: 2500    #涓嬬墖鐨勬渶澶у搴�
+  maxHeight: 2000   #涓嬬墖鐨勬渶澶ч珮搴�
+  minWidth: 400    #涓嬬墖鐨勬渶灏忓搴�
+  minHeight: 400   #涓嬬墖鐨勬渶灏忛珮搴�
+  throughWidth: 3000
+  throughHeight: 2500
+  threshold: 5      #涓嬬墖鐨勬渶澶ч槇鍊�
+  scan:
+    ip: 192.168.30.199
+    port: 5000
+kangaroohy:
+  milo:
+    enabled: false
\ No newline at end of file

--
Gitblit v1.8.0