From 0ce7d62e80382c7fcd61cfbd3f5a0403800cb243 Mon Sep 17 00:00:00 2001
From: Junjie <540245094@qq.com>
Date: 星期二, 12 十二月 2023 14:40:50 +0800
Subject: [PATCH] #找库位V2

---
 src/main/java/com/zy/asrs/service/impl/WrkMastServiceImpl.java |   39 +++++++++------------------------------
 1 files changed, 9 insertions(+), 30 deletions(-)

diff --git a/src/main/java/com/zy/asrs/service/impl/WrkMastServiceImpl.java b/src/main/java/com/zy/asrs/service/impl/WrkMastServiceImpl.java
index 2f977a0..a7d7031 100644
--- a/src/main/java/com/zy/asrs/service/impl/WrkMastServiceImpl.java
+++ b/src/main/java/com/zy/asrs/service/impl/WrkMastServiceImpl.java
@@ -49,23 +49,12 @@
         if (ioType != 11) {
             // 鍏ュ簱
             if (ioType < 100) {
-                List<String> groupOuterLoc = Utils.getGroupOuterLoc(locNo);
-                if (!Cools.isEmpty(groupOuterLoc)) {
-                    for (String outerLoc : groupOuterLoc) {
-                        WrkMast wrkMast = this.baseMapper.selectByLocNoOfPakin(outerLoc);
+                List<String> groupInnerLoc = Utils.getGroupInnerLoc(locNo);
+                if (!Cools.isEmpty(groupInnerLoc)) {
+                    for (String innerLoc : groupInnerLoc) {
+                        WrkMast wrkMast = this.baseMapper.selectByLocNoOfPakin(innerLoc);
                         if (wrkMast != null) {
                             defaultIoPri = wrkMast.getIoPri() - 2;
-//                            defaultIoPri = defaultIoPri == null ? wrkMast.getIoPri() - 2 : defaultIoPri - 2;
-                        }
-                    }
-                }
-                List<String> groupInsideLoc = Utils.getGroupInsideLoc(locNo);
-                if (!Cools.isEmpty(groupInsideLoc)) {
-                    for (String insideLoc : groupInsideLoc) {
-                        WrkMast wrkMast = this.baseMapper.selectByLocNoOfPakin(insideLoc);
-                        if (wrkMast != null) {
-                            defaultIoPri = wrkMast.getIoPri() + 2;
-//                            defaultIoPri = defaultIoPri == null ? wrkMast.getIoPri() + 2 : defaultIoPri + 2;
                         }
                     }
                 }
@@ -77,26 +66,12 @@
                         WrkMast wrkMast = this.baseMapper.selectBySourceLocNoOfPakout(outerLoc);
                         if (wrkMast != null) {
                             defaultIoPri = wrkMast.getIoPri() - 2;
-//                            defaultIoPri = defaultIoPri == null ? wrkMast.getIoPri() - 2 : defaultIoPri - 2;
-                        }
-                    }
-                }
-                List<String> groupInsideLoc = Utils.getGroupInsideLoc(locNo);
-                if (!Cools.isEmpty(groupInsideLoc)) {
-                    for (String insideLoc : groupInsideLoc) {
-                        WrkMast wrkMast = this.baseMapper.selectBySourceLocNoOfPakout(insideLoc);
-                        if (wrkMast != null) {
-                            defaultIoPri = wrkMast.getIoPri() + 2;
-//                            defaultIoPri = defaultIoPri == null ? wrkMast.getIoPri() + 2 : defaultIoPri + 2;
                         }
                     }
                 }
             }
-        // 绉诲簱
-        } else {
-//            @Deprecated
         }
-        return defaultIoPri == null ? 300.0D : defaultIoPri;
+        return defaultIoPri == null ? 100.0D : defaultIoPri;
     }
 
     @Override
@@ -120,4 +95,8 @@
         return this.baseMapper.selectSameMatnrs(matnr);
     }
 
+    @Override
+    public List<WrkMast> selectSameLevMatnrs(String matnr, Integer lev) {
+        return this.baseMapper.selectSameLevMatnrs(matnr, lev);
+    }
 }

--
Gitblit v1.9.1