-
-
Notifications
You must be signed in to change notification settings - Fork 345
FIX: [exchange] (coinbase) fill missing SubmitOrder #1920
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
Side: cbOrder.Side.GlobalSideType(), | ||
Quantity: cbOrder.Size, | ||
Price: cbOrder.Price, | ||
StopPrice: cbOrder.StopPrice, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
OrderType field is missing
and TimeInForce
@@ -12,12 +12,20 @@ import ( | |||
|
|||
func toGlobalOrder(cbOrder *api.Order) types.Order { | |||
return types.Order{ | |||
SubmitOrder: types.SubmitOrder{ | |||
ClientOrderID: cbOrder.ClientOID, | |||
Side: cbOrder.Side.GlobalSideType(), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
use toGlobalSide() instead of method,
because binding method will import the global types package from the api package.
Exchange: types.ExchangeCoinBase, | ||
Status: cbOrder.Status.GlobalOrderStatus(), | ||
UUID: cbOrder.ID, | ||
OrderID: FNV64a(cbOrder.ID), | ||
OriginalStatus: string(cbOrder.Status), | ||
CreationTime: cbOrder.CreatedAt, | ||
IsWorking: cbOrder.Status == api.OrderStatusOpen, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
partially fill also means IsWorking
As title.