From 9268cd77b4e864b901a8b0bf965f441f2e8c4fbd Mon Sep 17 00:00:00 2001
From: dubin <bindu_bean@163.com>
Date: 星期日, 04 一月 2026 08:06:14 +0800
Subject: [PATCH] #1

---
 src/main/java/com/zy/common/service/CommonService.java |   16 ++++++++++------
 1 files changed, 10 insertions(+), 6 deletions(-)

diff --git a/src/main/java/com/zy/common/service/CommonService.java b/src/main/java/com/zy/common/service/CommonService.java
index 27f3b06..313ed9c 100644
--- a/src/main/java/com/zy/common/service/CommonService.java
+++ b/src/main/java/com/zy/common/service/CommonService.java
@@ -1,6 +1,7 @@
 package com.zy.common.service;
 
 import com.baomidou.mybatisplus.mapper.EntityWrapper;
+import com.baomidou.mybatisplus.mapper.Wrapper;
 import com.core.common.Cools;
 import com.core.exception.CoolException;
 import com.zy.asrs.entity.*;
@@ -101,13 +102,13 @@
         StartupDto startupDto = null;
         StringBuilder builder = new StringBuilder();
         try {
-            startupDto = searchLocNoByCrnNo(staDescId, sourceStaNo, findLocNoAttributeVo, locTypeDto);
+            startupDto = searchLocNoByCrnNo(staDescId, sourceStaNo, findLocNoAttributeVo, locTypeDto,barcode);
         } catch (Exception e) {
             builder.append(e.getMessage()).append(",");
         }
 
         if(startupDto == null) {
-            builder.append("鎵句笉鍒扮┖搴撲綅");
+            builder.append("鎵句笉鍒扮┖搴撲綅--->" + barcode);
             throw new CoolException(builder.toString());
         }
 
@@ -124,14 +125,17 @@
      * @return locNo 妫�绱㈠埌鐨勫簱浣嶅彿
      */
     @Transactional
-    public StartupDto searchLocNoByCrnNo(Integer staDescId, Integer sourceStaNo, FindLocNoAttributeVo findLocNoAttributeVo, LocTypeDto locTypeDto) {
+    public StartupDto searchLocNoByCrnNo(Integer staDescId, Integer sourceStaNo, FindLocNoAttributeVo findLocNoAttributeVo, LocTypeDto locTypeDto,String barcode) {
         LocMast locMast = null;
         if (staDescId == 10) {
             //鎼滅储绌烘墭鐩�
-            locMast = searchEmptyPallet(locTypeDto);
+//            locMast = searchEmptyPallet(locTypeDto);
+            locMast = locMastService.selectOne(new EntityWrapper<LocMast>().eq("loc_sts","O").eq("barcode",barcode));
+
         }else {
             //婊℃墭鐩�
-            locMast = searchMaxPallet(findLocNoAttributeVo, locTypeDto);
+//            locMast = searchMaxPallet(findLocNoAttributeVo, locTypeDto);
+            locMast = locMastService.selectOne(new EntityWrapper<LocMast>().in("loc_sts","O","P").eq("barcode",barcode));
         }
 
         if(locMast == null) {
@@ -140,7 +144,7 @@
 
         StartupDto startupDto = new StartupDto();
 
-//        // 鑾峰彇鐩爣绔�
+        // 鑾峰彇鐩爣绔�
 //        Wrapper<StaDesc> wrapper = new EntityWrapper<StaDesc>().eq("type_no", staDescId).eq("stn_no", sourceStaNo).eq("crn_no", locMast.getCrnNo());
 //        StaDesc staDesc = staDescService.selectOne(wrapper);
 //        if (Cools.isEmpty(staDesc)) {

--
Gitblit v1.9.1