Support stop order in persistence

This commit is contained in:
Matthias 2020-06-01 10:36:23 +02:00
parent b58fd179f2
commit 1d9aeef792

View File

@ -374,7 +374,7 @@ class Trade(_DECL_BASE):
elif order_type in ('market', 'limit') and order['side'] == 'sell':
self.close(order['price'])
logger.info('%s_SELL has been fulfilled for %s.', order_type.upper(), self)
elif order_type in ('stop_loss_limit', 'stop-loss'):
elif order_type in ('stop_loss_limit', 'stop-loss', 'stop'):
self.stoploss_order_id = None
self.close_rate_requested = self.stop_loss
logger.info('%s is hit for %s.', order_type.upper(), self)