1、反向下单 暂时提交
This commit is contained in:
@ -12,6 +12,7 @@ import (
|
||||
"go-admin/models/binancedto"
|
||||
"go-admin/models/futuresdto"
|
||||
"go-admin/pkg/httputils"
|
||||
"go-admin/pkg/retryhelper"
|
||||
"go-admin/pkg/utility"
|
||||
"strconv"
|
||||
"strings"
|
||||
@ -715,6 +716,15 @@ func (e FutRestApi) ClosePosition(symbol string, orderSn string, quantity decima
|
||||
return nil
|
||||
}
|
||||
|
||||
// 带重试机制的取消订单
|
||||
func (e FutRestApi) CancelFutOrderRetry(apiUserInfo DbModels.LineApiUser, symbol string, newClientOrderId string) error {
|
||||
opts := retryhelper.DefaultRetryOptions()
|
||||
|
||||
return retryhelper.Retry(func() error {
|
||||
return e.CancelFutOrder(apiUserInfo, symbol, newClientOrderId)
|
||||
}, opts)
|
||||
}
|
||||
|
||||
// CancelFutOrder 通过单个订单号取消合约委托
|
||||
// symbol 交易对
|
||||
// newClientOrderId 系统自定义订单号
|
||||
|
||||
Reference in New Issue
Block a user