| | |
| | | transaction_progress.TradeBuyQueue().set_traded_index(code, 0) |
| | | |
| | | |
| | | |
| | | class VirtualTrade(unittest.TestCase): |
| | | |
| | | def __process_buy_queue(self, code, buy_queue, time_): |
| | |
| | | buy_progress_index = TradeBuyQueue().compute_traded_index(code, buy_one_price_, |
| | | buy_queue_result_list, exec_time) |
| | | if buy_progress_index is not None: |
| | | l2.cancel_buy_strategy.HourCancelBigNumComputer.set_trade_progress(code, time_, buy_exec_index, |
| | | l2.cancel_buy_strategy.HourCancelBigNumComputer().set_trade_progress(code, time_, |
| | | buy_exec_index, |
| | | buy_progress_index, |
| | | l2.l2_data_util.local_today_datas.get( |
| | | code), |
| | |
| | | RealTimeKplMarketData().set_top_5_reasons(jingxuan_ranks) |
| | | RealTimeKplMarketData().set_top_5_industry(industry_ranks) |
| | | |
| | | LimitUpCodesPlateKeyManager().set_today_limit_up(KPLDataManager().get_from_file(kpl_util.KPLDataType.LIMIT_UP, tool.get_now_date_str())) |
| | | LimitUpCodesPlateKeyManager().set_today_limit_up( |
| | | KPLDataManager().get_from_file(kpl_util.KPLDataType.LIMIT_UP, tool.get_now_date_str())) |
| | | |
| | | for indexs in pos_list: |
| | | l2_log.threadIds[code] = mock.Mock( |
| | |
| | | time_s = tool.get_time_as_second(time_) - i - 1 |
| | | volumn = THSBuy1VolumnManager().get_buy_1_volumn(code, tool.time_seconds_format(time_s)) |
| | | if volumn is not None: |
| | | l2.cancel_buy_strategy.L2LimitUpMoneyStatisticUtil().verify_num(code, int(volumn), tool.time_seconds_format(time_s)) |
| | | l2.cancel_buy_strategy.L2LimitUpMoneyStatisticUtil().verify_num(code, int(volumn), |
| | | tool.time_seconds_format(time_s)) |
| | | break |
| | | # 设置委买队列 |
| | | for i in range(0, len(buy_queues)): |
| | |
| | | l2.l2_data_util.load_num_operate_map(l2.l2_data_util.local_today_num_operate_map, code, total_datas, True) |
| | | |
| | | buy_progress_index = 523 |
| | | l2.cancel_buy_strategy.HourCancelBigNumComputer.set_trade_progress(code, buy_progress_index, |
| | | l2.cancel_buy_strategy.HourCancelBigNumComputer().set_trade_progress(code, buy_progress_index, |
| | | l2.l2_data_util.local_today_datas.get( |
| | | code), |
| | | l2.l2_data_util.local_today_num_operate_map.get( |