提交
This commit is contained in:
1 parent
1ca2668112
commit
5b3edb1700
278 files changed
+53761
-36931
No files matched your search
@@ -0,0 +1,12 @@
|
||||
-- 细胞产品规格改为文本存储(不再依赖 biz_cell_product_spec 下拉关联)
|
||||
ALTER TABLE `biz_cell_product`
|
||||
ADD COLUMN `spec_text` varchar(200) DEFAULT NULL COMMENT '规格(文本)' AFTER `spec_id`;
|
||||
|
||||
-- 历史数据:若已关联规格主数据,回填展示文本
|
||||
UPDATE `biz_cell_product` cp
|
||||
INNER JOIN `biz_cell_product_spec` s ON s.id = cp.spec_id AND s.del_flag = 0
|
||||
SET cp.spec_text = s.spec_name
|
||||
WHERE cp.del_flag = 0
|
||||
AND (cp.spec_text IS NULL OR cp.spec_text = '')
|
||||
AND cp.spec_id IS NOT NULL
|
||||
AND cp.spec_id != '';
|
||||
Reference in new issue
Block a user