From 5640d1300795c002438962386049bb65fb4f2216 Mon Sep 17 00:00:00 2001
From: 吴羡 <16976746+Xian-TT3@user.noreply.gitee.com>
Date: 星期二, 22 九月 2026 18:05:34 +0800
Subject: [PATCH] feat: 采购台账产品层级自动注册与材质字段、大类删除限制、审批模板启用后仅可修改状态
---
src/main/resources/mapper/sales/SalesLedgerProductMapper.xml | 7 ++++---
1 files changed, 4 insertions(+), 3 deletions(-)
diff --git a/src/main/resources/mapper/sales/SalesLedgerProductMapper.xml b/src/main/resources/mapper/sales/SalesLedgerProductMapper.xml
index 9e6839f..b60f454 100644
--- a/src/main/resources/mapper/sales/SalesLedgerProductMapper.xml
+++ b/src/main/resources/mapper/sales/SalesLedgerProductMapper.xml
@@ -26,9 +26,10 @@
T1.is_production,
T1.create_user,
T1.dept_id,
- p.product_name as product_category,
- pm.model as specification_model,
- pm.unit as unit,
+ COALESCE(NULLIF(T1.product_category, ''), p.product_name) as product_category,
+ T1.material,
+ COALESCE(NULLIF(T1.specification_model, ''), pm.model) as specification_model,
+ COALESCE(NULLIF(T1.unit, ''), pm.unit) as unit,
CASE
WHEN (IFNULL(t2.qualitity, 0) - IFNULL(t2.locked_quantity, 0)) >0 THEN 1
ELSE 0
--
Gitblit v1.9.3