按委托标识关联到期回报

This commit is contained in:
baobao 2026-11-19 16:53:52 +08:00
parent d99d658e48
commit b687a39230
1 changed files with 5 additions and 3 deletions

View File

@ -76,9 +76,11 @@ def plan():
quantity = int(first['before']['qty']) - int(last['after']['qty']) quantity = int(first['before']['qty']) - int(last['after']['qty'])
if late: if late:
for correction, amendment_seq, terminal_seq in zip(corrections, (1965761,1965781), (1965764,1965783), strict=True): for correction, amendment_seq, terminal_seq in zip(corrections, (1965761,1965781), (1965764,1965783), strict=True):
amendment = data(amendment_seq, 'order_update', code) amendment = trade_correction_repo.get_inbox(amendment_seq)
terminal = data(terminal_seq, 'order_update', code) terminal = trade_correction_repo.get_inbox(terminal_seq)
require(amendment['payload']['correction_id'] == correction['payload']['correction_id'], '对应更正配对序号变化') require(amendment and terminal and amendment['msg_type'] == 'order_update'
and amendment['payload'].get('correction_id') == correction['payload']['correction_id'],
'对应更正配对序号变化')
trade_correction._closed_recovery_terminal(amendment, terminal, order, qmt_repo.get_state()['last_seq']) trade_correction._closed_recovery_terminal(amendment, terminal, order, qmt_repo.get_state()['last_seq'])
closed_terminals[correction['seq']] = terminal closed_terminals[correction['seq']] = terminal
late_trade = late['payload'] late_trade = late['payload']