feat(hub): add period date range and trade stats to inner-light-mind

Support today/week/month/custom range selection with sick count, PnL, and per-exchange breakdown; update docs.

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
dekun
2026-06-11 18:09:39 +08:00
parent 5f79a62b13
commit 7b0b8996fe
7 changed files with 360 additions and 62 deletions
+7 -1
View File
@@ -2057,7 +2057,10 @@ def api_archive_list(
@app.get("/api/archive/daily-trades")
def api_archive_daily_trades(
period: str = "",
trading_day: str = "",
date_from: str = "",
date_to: str = "",
exchange_key: str = "",
filter_profit: str = "",
filter_loss: str = "",
@@ -2066,7 +2069,10 @@ def api_archive_daily_trades(
):
init_archive_db()
payload = list_daily_trades(
trading_day=trading_day or today_trading_day(),
trading_day=trading_day,
period=period or "today",
date_from=date_from,
date_to=date_to,
exchange_key=exchange_key,
filter_profit=(filter_profit or "").lower() in ("1", "true", "yes", "on"),
filter_loss=(filter_loss or "").lower() in ("1", "true", "yes", "on"),