admin/sql/migrate_t_order_is_paid.sql
zzh 095ad66717 feat(order): 增加 IsPaid 字段并修复列表状态筛选
- t_order 新增 IsPaid,支付/出库以该字段判断;含迁移脚本

- 列表接口补充 productName、channelName

- 修复 BuildOrderPredicate 状态条件 SqlSugar 翻译丢失

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-06-27 19:13:15 +08:00

8 lines
264 B
SQL
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

-- 订单表增加是否已支付字段,并按历史 PayTime 回填
ALTER TABLE `t_order`
ADD COLUMN `IsPaid` TINYINT NOT NULL DEFAULT 0 COMMENT '是否已支付:0-否,1-是' AFTER `PayTime`;
UPDATE `t_order`
SET `IsPaid` = 1
WHERE `PayTime` IS NOT NULL;