From 77140b11f195496f102b27190286a380c29e4dc9 Mon Sep 17 00:00:00 2001
From: zjj <3272660260@qq.com>
Date: 星期五, 18 十月 2024 08:56:19 +0800
Subject: [PATCH] #

---
 src/main/java/com/zy/common/service/CommonService.java |   21 +++++++++++++--------
 1 files changed, 13 insertions(+), 8 deletions(-)

diff --git a/src/main/java/com/zy/common/service/CommonService.java b/src/main/java/com/zy/common/service/CommonService.java
index e115601..619bcf2 100644
--- a/src/main/java/com/zy/common/service/CommonService.java
+++ b/src/main/java/com/zy/common/service/CommonService.java
@@ -209,7 +209,7 @@
 
         //姝ょ▼搴忕敤浜庝紭鍖栧爢鍨涙満寮傚父鏃剁殑杩愯鏃堕棿
         for (int i = times; i < crnNumber*2; i++) {
-            int[] locNecessaryParameters = Utils.LocNecessaryParameters(rowLastno, curRow, crnNumber);
+            int[] locNecessaryParameters = Utils.LocNecessaryParameters(rowLastno, curRow, crnNumber,whsType);
             curRow = locNecessaryParameters[1];
             crnNo = locNecessaryParameters[2];
             if (basCrnpService.checkSiteError(crnNo, true)) {
@@ -507,7 +507,7 @@
 
         //姝ょ▼搴忕敤浜庝紭鍖栧爢鍨涙満寮傚父鏃剁殑杩愯鏃堕棿
         for (int i = times; i < crnNumber*2; i++) {
-            int[] locNecessaryParameters = Utils.LocNecessaryParameters(rowLastno, curRow, crnNumber);
+            int[] locNecessaryParameters = Utils.LocNecessaryParameters(rowLastno, curRow, crnNumber,whsType);
             rowCount =  locNecessaryParameters[0];
             curRow = locNecessaryParameters[1];
             crnNo = locNecessaryParameters[2];
@@ -560,7 +560,7 @@
 
                 for (int i = 0; i < crnNumber*2; i++) {
                     if (!(Utils.getRow(locMastGro.getLocNo())>nearRowW && Utils.getRow(locMastGro.getLocNo())<=curRowW) && !(Utils.getRow(locMastGro.getLocNo())<nearRowW && Utils.getRow(locMastGro.getLocNo())>=curRowW) ){
-                        int[] locNecessaryParameters = Utils.LocNecessaryParameters(rowLastno, curRowW, crnNumber);
+                        int[] locNecessaryParameters = Utils.LocNecessaryParameters(rowLastno, curRowW, crnNumber,whsType);
                         curRowW = locNecessaryParameters[1];
                         nearRowW = locNecessaryParameters[3];
                     }else {
@@ -626,7 +626,7 @@
 
                 for (int i = 0; i < crnNumber*2; i++) {
                     if (!(Utils.getRow(locMastGro.getLocNo())>nearRowW && Utils.getRow(locMastGro.getLocNo())<=curRowW) && !(Utils.getRow(locMastGro.getLocNo())<nearRowW && Utils.getRow(locMastGro.getLocNo())>=curRowW) ){
-                        int[] locNecessaryParameters = Utils.LocNecessaryParameters(rowLastno, curRowW, crnNumber);
+                        int[] locNecessaryParameters = Utils.LocNecessaryParameters(rowLastno, curRowW, crnNumber,whsType);
                         curRowW = locNecessaryParameters[1];
                         nearRowW = locNecessaryParameters[3];
                     }else {
@@ -655,7 +655,7 @@
 
         // 闈犺繎鎽嗘斁瑙勫垯 --- 绌烘墭 //浜掗�氱増
         if (staDescId == 10  && Utils.BooleanWhsTypeStaIoType(rowLastno)) {
-            List<LocMast> locMasts = locMastService.selectList(new EntityWrapper<LocMast>().eq("loc_sts", "D").ge("row1", sRow).le("row1", eRow));
+            List<LocMast> locMasts = locMastService.selectList(new EntityWrapper<LocMast>().eq("loc_sts", "D").ge("row1", sRow).le("row1", eRow).eq("crn_no",7));
             int nearbay = 0;
             int nearlev = 0;
             for (LocMast locMastSign:locMasts){
@@ -678,7 +678,7 @@
 
                 for (int i = 0; i < crnNumber*2; i++) {
                     if (!(Utils.getRow(locMastGro.getLocNo())>nearRowW && Utils.getRow(locMastGro.getLocNo())<=curRowW) && !(Utils.getRow(locMastGro.getLocNo())<nearRowW && Utils.getRow(locMastGro.getLocNo())>=curRowW) ){
-                        int[] locNecessaryParameters = Utils.LocNecessaryParameters(rowLastno, curRowW, crnNumber);
+                        int[] locNecessaryParameters = Utils.LocNecessaryParameters(rowLastno, curRowW, crnNumber,whsType);
                         curRowW = locNecessaryParameters[1];
                         nearRowW = locNecessaryParameters[3];
                     }else {
@@ -696,7 +696,7 @@
                         bay2=Utils.getBay(locMast2.getLocNo())+1;
                     }
                     String targetLocNo = locMast2.getLocNo().substring(0,2)  +zerofill(String.valueOf(bay2), 3) + locMast2.getLocNo().substring(5);
-                    locMast = locMastService.selectOne(new EntityWrapper<LocMast>().eq("loc_no",targetLocNo).eq("loc_sts","O"));
+                    locMast = locMastService.selectOne(new EntityWrapper<LocMast>().eq("loc_no",targetLocNo).eq("crn_no",7).eq("loc_sts","O"));
                     if (Cools.isEmpty(locMast)){
                         continue;
                     }
@@ -742,7 +742,9 @@
             List<LocMast> locMasts = locMastService.selectList(new EntityWrapper<LocMast>()
                     .eq("bay1", nearRow)
                     .eq("loc_sts", "O").eq("whs_type",rowLastnoType.getType().longValue())
+                    .eq("crn_no",7)
                     .orderBy("lev1",true).orderBy("row1",false));//鏈�娴呭簱浣�
+
             for (LocMast locMast1 : locMasts) {
                 if (locMast != null){
                     break;
@@ -761,15 +763,18 @@
                     if (curRow < nearRow){
                         locMasts1 = locMastService.selectList(new EntityWrapper<LocMast>()
                                 .eq("gro1", locMast1.getGro1())
+                                .eq("crn_no",7)
                                 .orderBy("bay1",true));
                         if(locMasts1.size() == 3  || (curRow>20 && locMasts1.size() == 2)){
                             locMasts1 = locMastService.selectList(new EntityWrapper<LocMast>()
                                     .eq("gro1", locMast1.getGro1())
+                                    .eq("crn_no",7)
                                     .orderBy("bay1",false));
                         }
                     }else {
                         locMasts1 = locMastService.selectList(new EntityWrapper<LocMast>()
                                 .eq("gro1", locMast1.getGro1())
+                                .eq("crn_no",7)
                                 .orderBy("bay1",false));
                     }
                     if (Cools.isEmpty(locMasts1)) {
@@ -879,7 +884,7 @@
         }
 
         //姝ょ▼搴忕敤浜庝紭鍖栧爢鍨涙満寮傚父鏃剁殑杩愯鏃堕棿
-        int[] locNecessaryParameters = Utils.LocNecessaryParameters(rowLastno, curRow, crnNumber);
+        int[] locNecessaryParameters = Utils.LocNecessaryParameters(rowLastno, curRow, crnNumber,whsType);
         curRow = locNecessaryParameters[1];
         crnNo = locNecessaryParameters[2];
         rowCount =  locNecessaryParameters[0];

--
Gitblit v1.9.1