fix: ec_order 表添加复合唯一约束 uk_company_shop_platform

This commit is contained in:
小蟑螂
2026-03-29 19:34:10 +08:00
parent 5a28c3bbb3
commit 5095c6f397
+1
View File
@@ -144,6 +144,7 @@ CREATE TABLE `ec_order` (
`create_by` bigint unsigned DEFAULT NULL COMMENT '创建人ID',
`update_by` bigint unsigned DEFAULT NULL COMMENT '更新人ID',
PRIMARY KEY (`id`),
UNIQUE KEY `uk_company_shop_platform` (`company_id`, `shop_id`, `platform_order_no`),
KEY `idx_company_shop_time` (`company_id`,`shop_id`,`order_time`),
KEY `idx_status_id` (`status_id`),
KEY `idx_platform_order_no` (`platform_order_no`),