1、交易对黑名单 交易所下架的交易对直接删除
This commit is contained in:
@ -159,3 +159,14 @@ func GetSymbolTriggerCount(db *gorm.DB, symbol string, apiId, symbolType int) (i
|
||||
// func GetOpenedOrders(db *gorm.DB, apiId int, exchange, symbol, symbolType, side string) ([]models.LinePreOrder, error) {
|
||||
|
||||
// }
|
||||
|
||||
// 获取子订单止盈止损数量
|
||||
func GetChildTpOrder(db *gorm.DB, pid int) (int, error) {
|
||||
var count int64
|
||||
|
||||
if err := db.Model(&models.LinePreOrder{}).Where("pid =? AND order_type>0 and order_type <3 and status =0", pid).Count(&count).Error; err != nil {
|
||||
return 0, err
|
||||
}
|
||||
|
||||
return int(count), nil
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user