From fe058347969127ef92e85f89623abde268b29fab Mon Sep 17 00:00:00 2001
From: buhuazhen <hua100783@gmail.com>
Date: 星期五, 15 五月 2026 17:22:57 +0800
Subject: [PATCH] feat(销售报价) 添加productId 和 productModelId
---
src/main/resources/mapper/sales/SalesLedgerProductMapper.xml | 4 +++-
1 files changed, 3 insertions(+), 1 deletions(-)
diff --git a/src/main/resources/mapper/sales/SalesLedgerProductMapper.xml b/src/main/resources/mapper/sales/SalesLedgerProductMapper.xml
index f3fa32d..7e352d8 100644
--- a/src/main/resources/mapper/sales/SalesLedgerProductMapper.xml
+++ b/src/main/resources/mapper/sales/SalesLedgerProductMapper.xml
@@ -48,7 +48,8 @@
END as has_sufficient_stock,
(IFNULL(T1.quantity, 0) - IFNULL(t3.shipped_quantity, 0)) as no_quantity,
CASE
- WHEN (IFNULL(T1.quantity, 0) - IFNULL(t3.shipped_quantity, 0)) > 0 THEN '寰呭彂璐�'
+ WHEN IFNULL(t3.shipped_quantity, 0) = 0 THEN '寰呭彂璐�'
+ WHEN (IFNULL(T1.quantity, 0) - IFNULL(t3.shipped_quantity, 0)) > 0 THEN '閮ㄥ垎鍙戣揣'
ELSE '宸插彂璐�'
END as shippingStatus
FROM
@@ -62,6 +63,7 @@
SELECT sales_ledger_product_id, IFNULL(SUM(spd.quantity), 0) as shipped_quantity
FROM shipping_info si
LEFT JOIN shipping_product_detail spd ON si.id = spd.shipping_info_id
+ where si.status != '瀹℃牳鎷掔粷'
GROUP BY sales_ledger_product_id
) t3 ON t3.sales_ledger_product_id = T1.id
left join product_model pm ON T1.product_model_id = pm.id
--
Gitblit v1.9.3