fix: 普适指标重复import bug(守卫回滚后补)+前端普适列显示有效年/总年

This commit is contained in:
xxm
2026-08-17 01:32:28 +08:00
parent 4a78664f72
commit a82b8c72b7
2 changed files with 3 additions and 3 deletions
@@ -169,7 +169,6 @@ def process_period(conn, market, period_tag):
_univ_score = _univ_years = _univ_valid = _univ_leave1 = 0
_ed_list = [t.get("entry_date", "")[:4] for t in reg_trades if t.get("entry_date")]
if len(_ed_list) >= 5:
from collections import defaultdict
_yr = defaultdict(list)
for _y, _t in zip(_ed_list, reg_trades):
_yr[_y].append(_t.get("profit_pct", 0))