From e2ed35c5dbda6ff80fddf5f0ae1fe39ad407fb6b Mon Sep 17 00:00:00 2001
From: zhangc <zc@123>
Date: 星期日, 02 三月 2025 14:47:07 +0800
Subject: [PATCH] 四期

---
 src/main/java/com/zy/common/service/AgvCommonService.java |   24 +++++++++++++++++++++++-
 1 files changed, 23 insertions(+), 1 deletions(-)

diff --git a/src/main/java/com/zy/common/service/AgvCommonService.java b/src/main/java/com/zy/common/service/AgvCommonService.java
index c7903e4..4765df5 100644
--- a/src/main/java/com/zy/common/service/AgvCommonService.java
+++ b/src/main/java/com/zy/common/service/AgvCommonService.java
@@ -128,7 +128,11 @@
 //                locMast = locUtils.getLocNoRuleByFloor(type, floor, isEmpty, 2);
 //            } else {
 //                //涓嶅姩杩欎釜閫昏緫
-            locMast = getLocNoRule(type, floor, isEmpty, isCurrLev);
+            if (type == 6) {
+                locMast = locUtils.getLocNoRuleByFloor(type, floor);
+            } else {
+                locMast = getLocNoRule(type, floor, isEmpty, isCurrLev);
+            }
 //            }
             if (locMast != null) {
                 return locMast;
@@ -299,6 +303,24 @@
         throw new CoolException("鎼滅储搴撲綅鏃讹紝妤煎眰鍑洪敊銆�");
     }
 
+    public AgvLocMast getLocNoOnXiSuer(int type, int floor) {
+        EntityWrapper<AgvLocMast> wrapper = new EntityWrapper<>();
+        wrapper.eq("loc_sts", "O").eq("loc_type1", type);
+        wrapper.eq("floor", floor).orderBy("lev1", false);
+        List<AgvLocMast> agvLocMasts = agvLocMastService.selectList(wrapper);
+        if (Cools.isEmpty(agvLocMasts)) {
+            return null;
+        } else {
+            for (AgvLocMast agvLocMast : agvLocMasts) {
+                AgvLocMast agvLocMast1 = agvLocMastService.selectOne(new EntityWrapper<AgvLocMast>().eq("loc_no", agvLocMast.getLocNo()));
+                if (agvLocMast1.getLocSts().equals("O")) {
+                    return agvLocMast1;
+                }
+            }
+        }
+        return null;
+    }
+
 
     //闅忔満鍙栦竴涓揣浣�
     private AgvLocMast getLocNoRule(int type, int floor, boolean isEmpty, boolean isCurrLev) {

--
Gitblit v1.9.1