This commit is contained in:
lz_db
2025-12-02 15:17:58 +08:00
parent 502a0c49f2
commit be4c883d62
5 changed files with 391 additions and 21 deletions

View File

@@ -772,11 +772,14 @@ class mt5(Exchange, ImplicitAPI):
else:
# 如果无法解析,使用原始 market_id
symbol = market_id
timestamp = self.parse8601(self.safe_string(order, 'openTime')) - self.diff_milliseconds
last_trade_timestamp = self.parse8601(self.safe_string(order, 'closeTime')) - self.diff_milliseconds
if last_trade_timestamp is None:
timestamp = self.safe_integer(order, 'openTimestampUTC') - self.diff_milliseconds
last_trade_timestamp = self.safe_integer(order, 'closeTimestampUTC')
if last_trade_timestamp is None or last_trade_timestamp <= 0:
last_trade_timestamp = timestamp
else:
last_trade_timestamp = last_trade_timestamp - self.diff_milliseconds
status = self.parse_order_status(self.safe_string(order, 'state'))
side = self.parse_order_side(self.safe_string(order, 'orderType'))