1
This commit is contained in:
@ -158,6 +158,7 @@ func handleReduceFilled(db *gorm.DB, preOrder *DbModels.LinePreOrder) {
|
||||
}
|
||||
|
||||
totalNum := getFuturesPositionAvailableQuantity(db, apiUserInfo, preOrder, tradeSet)
|
||||
totalNum = totalNum.Truncate(int32(tradeSet.AmountDigit))
|
||||
futApi := FutRestApi{}
|
||||
for _, v := range orders {
|
||||
if v.OrderType == 1 {
|
||||
@ -383,10 +384,10 @@ func handleFutMainOrderFilled(db *gorm.DB, preOrder *models.LinePreOrder) {
|
||||
|
||||
futApi := FutRestApi{}
|
||||
num := getFuturesPositionAvailableQuantity(db, apiInfo, preOrder, tradeSet)
|
||||
num = num.Truncate(int32(tradeSet.AmountDigit))
|
||||
|
||||
for _, order := range orders {
|
||||
price := utility.StrToDecimal(order.Price).Truncate(int32(tradeSet.PriceDigit))
|
||||
num = num.Truncate(int32(tradeSet.AmountDigit))
|
||||
order.Price = price.String()
|
||||
|
||||
if order.OrderType == 4 {
|
||||
|
||||
Reference in New Issue
Block a user