mirror of
https://github.com/discountry/ritmex-bot.git
synced 2026-09-11 17:28:08 +00:00
refactor: extract shared adapter utilities (safeInvoke + initManager)
Created src/exchanges/adapter-utils.ts with createSafeInvoke() and createInitManager() factories. Converted 7/8 adapters to use shared utilities, eliminating ~350 lines of duplicated retry/init/error-handling boilerplate. Lighter adapter kept as-is (no retry logic by design). Also translated Chinese comments in adapter.ts and order-schema.ts.
This commit is contained in:
@@ -13,9 +13,8 @@ export interface BaseOrderIntent {
|
||||
|
||||
export interface LimitOrderIntent extends BaseOrderIntent {
|
||||
price: number;
|
||||
// StandX TPSL 参数
|
||||
slPrice?: number; // 止损价格
|
||||
tpPrice?: number; // 止盈价格
|
||||
slPrice?: number;
|
||||
tpPrice?: number;
|
||||
}
|
||||
|
||||
export interface MarketOrderIntent extends BaseOrderIntent {
|
||||
|
||||
Reference in New Issue
Block a user