maxapi/v3: apply order type constant type

This commit is contained in:
c9s 2022-08-09 18:52:59 +08:00
parent 2f8020efd6
commit 2380ebb285
No known key found for this signature in database
GPG Key ID: 7385E7E464CB0A54
2 changed files with 2 additions and 2 deletions

View File

@ -14,7 +14,7 @@ type CreateWalletOrderRequest struct {
market string `param:"market,required"`
side string `param:"side,required"`
volume string `param:"volume,required"`
orderType string `param:"ord_type"`
orderType OrderType `param:"ord_type"`
price *string `param:"price"`
stopPrice *string `param:"stop_price"`

View File

@ -27,7 +27,7 @@ func (c *CreateWalletOrderRequest) Volume(volume string) *CreateWalletOrderReque
return c
}
func (c *CreateWalletOrderRequest) OrderType(orderType string) *CreateWalletOrderRequest {
func (c *CreateWalletOrderRequest) OrderType(orderType max.OrderType) *CreateWalletOrderRequest {
c.orderType = orderType
return c
}