Administrator
2024-05-07 4aa347de9fc0fbfc21113869744def40fbaad39d
添加委托列表板块输出
2个文件已修改
15 ■■■■ 已修改文件
l2/l2_transaction_data_processor.py 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
trade/huaxin/huaxin_trade_server.py 11 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
l2/l2_transaction_data_processor.py
@@ -107,8 +107,8 @@
                        need_cancel, cancel_msg = FCancelBigNumComputer().need_cancel_for_p(code, big_sell_order_info,
                                                                                            order_begin_pos)
                    # 判断时间是否与本地时间相差5s以上
                    if tool.trade_time_sub(tool.get_now_time_str(), l2_huaxin_util.convert_time(datas[-1][3])) >= 5:
                        need_cancel, cancel_msg = True, f"成交时间与本地时间相差5S以上,{l2_huaxin_util.convert_time(datas[-1][3])}"
                    if tool.trade_time_sub(tool.get_now_time_str(), l2_huaxin_util.convert_time(datas[-1][3])) > 10:
                        need_cancel, cancel_msg = True, f"成交时间与本地时间相差10S以上,{l2_huaxin_util.convert_time(datas[-1][3])}"
                    if need_cancel:
                        L2TradeDataProcessor.cancel_buy(code, cancel_msg)
trade/huaxin/huaxin_trade_server.py
@@ -1552,7 +1552,6 @@
                                            break
                            except:
                                pass
                            fdata = {"code_info": (code, code_name), "total_num": total_nums,
                                     "finish_num": deal_or_cancel_num,
                                     "buy1_money": output_util.money_desc(buy1_money),
@@ -1573,8 +1572,16 @@
                                     "trade_progress_percent": round(
                                         total_left_num * float(limit_up_price) * 100 * 100 / buy1_money, 2),  # 成交进度比例
                                     "limit_up_price": float(gpcode_manager.get_limit_up_price(code)),
                                     "is_near_big_order": is_near_big_order
                                     "is_near_big_order": is_near_big_order,
                                     "block":''
                                     }
                            # 获取当前板块
                            try:
                                can_buy_result = CodePlateKeyBuyManager.can_buy(code)
                                if can_buy_result and can_buy_result[0]:
                                    fdata['block'] = ",".join(can_buy_result[0])
                            except:
                                pass
                            fdatas.append(fdata)
                        except Exception as e:
                            logger_debug.exception(e)