mirror of
https://github.com/c9s/bbgo.git
synced 2024-11-10 09:11:55 +00:00
support: add target orders to the orders
This commit is contained in:
parent
e5db780be8
commit
f66095eff9
|
@ -312,10 +312,11 @@ func (s *Strategy) Run(ctx context.Context, orderExecutor bbgo.OrderExecutor, se
|
|||
})
|
||||
}
|
||||
|
||||
_, err = orderExecutor.SubmitOrders(ctx, targetOrders...)
|
||||
createdOrders, err = orderExecutor.SubmitOrders(ctx, targetOrders...)
|
||||
if err != nil {
|
||||
log.WithError(err).Error("submit profit target order error")
|
||||
}
|
||||
s.orderStore.Add(createdOrders...)
|
||||
})
|
||||
|
||||
s.Graceful.OnShutdown(func(ctx context.Context, wg *sync.WaitGroup) {
|
||||
|
|
Loading…
Reference in New Issue
Block a user