feat: resolve and persist actual order venue
This commit is contained in:
@@ -0,0 +1,20 @@
|
||||
-- dcy-041 / GitHub #44: AUTO may exist while an intent is pending, but the
|
||||
-- actual submitted KRX/NXT value replaces it atomically with broker_order_id.
|
||||
ALTER TABLE daily_slot
|
||||
DROP CONSTRAINT IF EXISTS daily_slot_venue_check;
|
||||
|
||||
ALTER TABLE daily_slot
|
||||
ADD CONSTRAINT daily_slot_venue_check
|
||||
CHECK (venue IN ('AUTO', 'KRX', 'NXT', 'SOR'));
|
||||
|
||||
-- Core keeps the actual venue in its durable ledger outbox. Portfolio Hub's
|
||||
-- HTTP schema is intentionally unchanged in this migration.
|
||||
ALTER TABLE ledger_outbox
|
||||
ADD COLUMN IF NOT EXISTS venue TEXT NOT NULL DEFAULT 'KRX';
|
||||
|
||||
ALTER TABLE ledger_outbox
|
||||
DROP CONSTRAINT IF EXISTS ledger_outbox_venue_check;
|
||||
|
||||
ALTER TABLE ledger_outbox
|
||||
ADD CONSTRAINT ledger_outbox_venue_check
|
||||
CHECK (venue IN ('AUTO', 'KRX', 'NXT', 'SOR'));
|
||||
Reference in New Issue
Block a user