From c3551de690694ea9cb44702b289c0d1539676c44 Mon Sep 17 00:00:00 2001
From: liding <756868258@qq.com>
Date: 星期五, 22 五月 2026 11:35:36 +0800
Subject: [PATCH] fix(stock):库存展示数量大于0的

---
 src/main/resources/mapper/stock/StockInventoryMapper.xml |    2 ++
 1 files changed, 2 insertions(+), 0 deletions(-)

diff --git a/src/main/resources/mapper/stock/StockInventoryMapper.xml b/src/main/resources/mapper/stock/StockInventoryMapper.xml
index 72f6e6f..4601f68 100644
--- a/src/main/resources/mapper/stock/StockInventoryMapper.xml
+++ b/src/main/resources/mapper/stock/StockInventoryMapper.xml
@@ -203,6 +203,7 @@
             </if>
         </where>
         group by product_model_id, model, unit, product_name, product_id, unQualifiedBatchNo, materialCode, processCategory, voltage
+        having SUM(qualifiedQuantity) > 0 or SUM(unQualifiedQuantity) > 0
     </select>
 
     <select id="listStockInventoryExportData" resultType="com.ruoyi.stock.execl.StockInventoryExportData">
@@ -296,6 +297,7 @@
             </if>
         </where>
         group by product_model_id, model, unit, product_name, unQualifiedBatchNo, materialCode, processCategory, voltage
+        having SUM(qualifiedQuantity) > 0 or SUM(unQualifiedQuantity) > 0
     </select>
     <select id="stockInventoryPage" resultType="com.ruoyi.stock.dto.StockInRecordDto">
         select sir.*,si.qualitity as current_stock,

--
Gitblit v1.9.3