ForgeFlow-ERP/backend/sql/lite_flow_patch.sql
2026-06-12 16:00:56 +08:00

13 lines
658 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.

-- Lite 化流程兼容补丁:原材料驱动、客供料入库、无订单发货。
ALTER TABLE pp_work_order
MODIFY COLUMN work_order_no VARCHAR(80) NOT NULL COMMENT '生产跟踪号/历史生产工单号';
ALTER TABLE so_delivery
MODIFY COLUMN sales_order_id BIGINT NULL COMMENT '来源订单IDlite模式下可为空',
ADD COLUMN customer_id BIGINT NULL COMMENT '收货客户ID无订单发货时必填' AFTER sales_order_id;
ALTER TABLE so_delivery_item
MODIFY COLUMN sales_order_item_id BIGINT NULL COMMENT '来源订单明细IDlite模式下可为空';
CREATE INDEX idx_so_delivery_customer_id ON so_delivery (customer_id);