From 2fd3c6bb36ba489fed3f7078d76dce8e1d27cc36 Mon Sep 17 00:00:00 2001 From: Administrator <admin@example.com> Date: 星期五, 27 六月 2025 15:16:44 +0800 Subject: [PATCH] bug修复 --- code_atrribute/position_code_data_manager.py | 5 ++++- 1 files changed, 4 insertions(+), 1 deletions(-) diff --git a/code_atrribute/position_code_data_manager.py b/code_atrribute/position_code_data_manager.py index 9aa42fd..b3fd592 100644 --- a/code_atrribute/position_code_data_manager.py +++ b/code_atrribute/position_code_data_manager.py @@ -25,7 +25,10 @@ for d in datas: code = d[0] price = d[1] + buy1_price = d[5] volume = d[3] + if not price or price <= 0.0: + price = buy1_price cls.__current_price_dict[code] = price cls.__current_buy1_data_dict[code] = (d[5], d[6]) cls.__current_volume_dict[code] = volume @@ -56,4 +59,4 @@ if bars: code = bars[0]['symbol'].split(".")[1] volume = bars[0]['volume'] - cls.__pre_day_volume_dict[code] = volume \ No newline at end of file + cls.__pre_day_volume_dict[code] = volume -- Gitblit v1.8.0