This commit is contained in:
2025-02-19 17:03:16 +08:00
parent 597dbc78b8
commit b132ee879b
2 changed files with 3 additions and 5 deletions

View File

@ -58,7 +58,7 @@ func (s *SpiderListenSymbolInsertReq) Generate(model *models.SpiderListenSymbol)
model.Coin = strings.ToUpper(s.Coin) model.Coin = strings.ToUpper(s.Coin)
model.Currency = strings.ToUpper(s.Currency) model.Currency = strings.ToUpper(s.Currency)
model.Symbol = s.Coin + s.Currency model.Symbol = model.Coin + model.Currency
model.CreateBy = s.CreateBy // 添加这而,需要记录是被谁创建的 model.CreateBy = s.CreateBy // 添加这而,需要记录是被谁创建的
} }
@ -94,7 +94,7 @@ func (s *SpiderListenSymbolUpdateReq) Generate(model *models.SpiderListenSymbol)
// model.Symbol = s.Symbol // model.Symbol = s.Symbol
model.Coin = strings.ToUpper(s.Coin) model.Coin = strings.ToUpper(s.Coin)
model.Currency = strings.ToUpper(s.Currency) model.Currency = strings.ToUpper(s.Currency)
model.Symbol = s.Coin + s.Currency model.Symbol = model.Coin + model.Currency
model.UpdateBy = s.UpdateBy // 添加这而,需要记录是被谁更新的 model.UpdateBy = s.UpdateBy // 添加这而,需要记录是被谁更新的
} }

View File

@ -27,8 +27,6 @@ import (
"github.com/bytedance/sonic" "github.com/bytedance/sonic"
"gorm.io/driver/mysql" "gorm.io/driver/mysql"
"github.com/shopspring/decimal"
"github.com/go-admin-team/go-admin-core/sdk" "github.com/go-admin-team/go-admin-core/sdk"
"gorm.io/gorm" "gorm.io/gorm"
@ -314,8 +312,8 @@ func (t LimitOrderTimeoutDuration) ReFutOrderPlace(db *gorm.DB, order models.Lin
Price: utility.StringToDecimal(order.Price), Price: utility.StringToDecimal(order.Price),
SideType: "MARKET", SideType: "MARKET",
OpenOrder: 0, OpenOrder: 0,
Profit: decimal.Decimal{},
StopPrice: utility.StringToDecimal(order.Price), StopPrice: utility.StringToDecimal(order.Price),
Profit: utility.StringToDecimal(order.Price),
OrderType: orderType, OrderType: orderType,
NewClientOrderId: utility.Int64ToString(newClientOrderId), NewClientOrderId: utility.Int64ToString(newClientOrderId),
} }