From 1d2d3760bef94013f80cae555bdcbfb2268929a2 Mon Sep 17 00:00:00 2001
From: liding <756868258@qq.com>
Date: 星期三, 15 四月 2026 11:22:17 +0800
Subject: [PATCH] fix:生产-质量-仓储(合格,不合格),批号,供应商

---
 src/main/resources/mapper/stock/StockUninventoryMapper.xml |   24 +++++++++++++++++++++---
 1 files changed, 21 insertions(+), 3 deletions(-)

diff --git a/src/main/resources/mapper/stock/StockUninventoryMapper.xml b/src/main/resources/mapper/stock/StockUninventoryMapper.xml
index 6c5d3be..1e6e434 100644
--- a/src/main/resources/mapper/stock/StockUninventoryMapper.xml
+++ b/src/main/resources/mapper/stock/StockUninventoryMapper.xml
@@ -23,6 +23,12 @@
             <if test="ew.remark != null and ew.remark !=''">
                 remark = #{ew.remark},
             </if>
+            <if test="ew.batchNo != null and ew.batchNo !=''">
+                batch_no = #{ew.batchNo},
+            </if>
+            <if test="ew.customer != null and ew.customer !=''">
+                customer = #{ew.customer},
+            </if>
             update_time = now()
         </set>
         where product_model_id = #{ew.productModelId} and qualitity >= #{ew.qualitity}
@@ -38,6 +44,15 @@
             </if>
             <if test="ew.remark != null and ew.remark !=''">
                 remark = #{ew.remark},
+            </if>
+            <if test="ew.batchNo != null and ew.batchNo !=''">
+                batch_no = #{ew.batchNo},
+            </if>
+            <if test="ew.customer != null and ew.customer !=''">
+                customer = #{ew.customer},
+            </if>
+            <if test="ew.productionDate != null">
+                production_date = #{ew.productionDate},
             </if>
             update_time = now()
         </set>
@@ -55,16 +70,19 @@
         (su.qualitity - COALESCE(su.locked_quantity, 0)) as un_locked_quantity,
         pm.model,
         pm.unit,
-        p.product_name
+        pm.uid_no,
+        p.product_name,
+        su.batch_no,
+        su.customer
         from stock_uninventory su
         left join product_model pm on su.product_model_id = pm.id
         left join product p on pm.product_id = p.id
-        where 1 = 1
+        where su.qualitity != 0
         <if test="ew.productName != null and ew.productName !=''">
             and p.product_name like concat('%',#{ew.productName},'%')
         </if>
     </select>
-    <select id="listStockInventoryExportData" resultType="com.ruoyi.stock.execl.StockInventoryExportData">
+    <select id="listStockInventoryExportData" resultType="com.ruoyi.stock.execl.StockUnInventoryExportData">
         select su.*,
         pm.model,
         pm.unit,

--
Gitblit v1.9.3