main.py | ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史 |
main.py
@@ -369,6 +369,9 @@ async_log_util.info(logger_trade, f"准备下单:{cb_code}-{buy_price}-{buy_info}") # 买入20股 result = huaxin_trade_api.order(1, cb_code, volume, buy_price, blocking=True) if type(result) == dict and result['code'] == 0: orderRef = result['data']['orderRef'] async_log_util.info(logger_trade, f"可转载策略下单结果:({orderRef},{strategy_type})") CodeTradeStateManager().set_trade_state(cb_code, strategy_type, CodeTradeStateManager.TRADE_STATE_ALREADY_BUY) # 移除想买单