diff options
Diffstat (limited to 'frontend/src/pages/RunsPage.svelte')
| -rw-r--r-- | frontend/src/pages/RunsPage.svelte | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/frontend/src/pages/RunsPage.svelte b/frontend/src/pages/RunsPage.svelte index 154fd67..ad72b5d 100644 --- a/frontend/src/pages/RunsPage.svelte +++ b/frontend/src/pages/RunsPage.svelte @@ -6,6 +6,7 @@ import { listRuns } from '../lib/client'; import { extractStatusMessage } from '../lib/state'; import { fmtDateTime, runStatusLabel, runStatusBadge, fmtPct, fmtNum, formatMoney } from '../lib/format'; +import { capitalReporting } from '../lib/capitalMetrics'; import type { Run } from '../lib/types'; let runs: Run[] = $state([]); @@ -88,6 +89,11 @@ } mk('状态', selected.map((r) => runStatusLabel[r.status])); mk('时间', selected.map((r) => r.created_at)); + // 投入口径 reporting(任务 A):与结果页同口径,不含初始闲置现金 + const caps = selected.map((r) => (r.result ? capitalReporting(r.result) : null)); + mk('累计投入', caps.map((c) => (c ? formatMoney(c.invested) : '—'))); + mk('持仓估值', caps.map((c) => (c ? formatMoney(c.holdingValue) : '—'))); + mk('投入回报率', caps.map((c) => (c ? (c.returnPct ?? '—') : '—'))); return rows; }); </script> |
