feat(HEL-421): 回补历史日历和指数并标记区间不完整

Co-authored-by: Cursor <cursoragent@cursor.com>
Co-authored-by: multica-agent <github@multica.ai>
This commit is contained in:
总工
2026-09-02 22:16:05 +08:00
co-authored by Cursor multica-agent
parent 25ff6bbe06
commit a836cda1b2
18 changed files with 715 additions and 33 deletions
+11 -1
View File
@@ -51,7 +51,17 @@ RAW = {
def fake_transport(api_name: str, params: dict, fields: str):
if api_name == "index_daily":
code = params.get("ts_code")
return [row for row in RAW["index_daily"] if row["ts_code"] == code]
rows = [row for row in RAW["index_daily"] if row["ts_code"] == code]
trade_date = str(params.get("trade_date") or "")
start = str(params.get("start_date") or "")
end = str(params.get("end_date") or "")
if trade_date:
rows = [row for row in rows if row["trade_date"] == trade_date]
if start:
rows = [row for row in rows if row["trade_date"] >= start]
if end:
rows = [row for row in rows if row["trade_date"] <= end]
return rows
if api_name == "trade_cal":
start = str(params.get("start_date") or "")
end = str(params.get("end_date") or "99999999")