Update open price when position filled to match more the reality
This commit is contained in:
@@ -418,6 +418,9 @@ public class TradingBotBase : ITradingBot
|
||||
internalPosition.Open.SetStatus(TradeStatus.Filled);
|
||||
positionForSignal.Open.SetStatus(TradeStatus.Filled);
|
||||
|
||||
internalPosition.Open.SetPrice(brokerPosition.Open.Price, 5);
|
||||
positionForSignal.Open.SetPrice(brokerPosition.Open.Price, 5);
|
||||
|
||||
// Update Open trade ExchangeOrderId if broker position has one
|
||||
if (brokerPosition.Open?.ExchangeOrderId != null && internalPosition.Open != null)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user