From 8af4cdbdb52932dca5d16fbce42a2f6fad4e3b8b Mon Sep 17 00:00:00 2001
From: Administrator <1051256694@qq.com>
Date: 星期六, 28 三月 2026 14:59:29 +0800
Subject: [PATCH] #

---
 src/main/resources/mapper/OrderDetlPakoutMapper.xml |   21 +++++++++++++--------
 1 files changed, 13 insertions(+), 8 deletions(-)

diff --git a/src/main/resources/mapper/OrderDetlPakoutMapper.xml b/src/main/resources/mapper/OrderDetlPakoutMapper.xml
index 7f70401..2dde019 100644
--- a/src/main/resources/mapper/OrderDetlPakoutMapper.xml
+++ b/src/main/resources/mapper/OrderDetlPakoutMapper.xml
@@ -57,13 +57,18 @@
 
     <sql id="standbyAll">
         and batch = #{batch}
-        and brand = #{brand}
-        and standby1 = #{standby1}
-        and standby2 = #{standby2}
-        and standby3 = #{standby3}
-        and box_type1 = #{boxType1}
-        and box_type2 = #{boxType2}
-        and box_type3 = #{boxType3}
+        <if test="brand != null and brand != ''">
+            and brand = #{brand}
+        </if>
+        <if test="standby1 != null and standby1 != ''">
+            and standby1 = #{standby1}
+        </if>
+        <if test="standby2 != null and standby2 != ''">
+            and standby2 = #{standby2}
+        </if>
+        <if test="standby3 != null and standby3 != ''">
+            and standby3 = #{standby3}
+        </if>
     </sql>
     <sql id="standbyAllMemo">
         --         and line_number = #{lineNumber}
@@ -79,7 +84,7 @@
     </select>
 
     <select id="selectItemByOrderNo" resultMap="BaseResultMap">
-        select * from man_order_detl_pakout
+        select top 1 * from man_order_detl_pakout
         where 1=1
         and order_no = #{orderNo}
         and matnr = #{matnr}

--
Gitblit v1.9.1