feat: add public h5 dashboard and publish traceability

This commit is contained in:
Wyndham ARR
2026-08-03 13:04:41 +08:00
parent 7e7470821b
commit 2107f00e32
29 changed files with 1047 additions and 71 deletions

View File

@@ -0,0 +1,29 @@
# ADR-005: Public Read-Only H5 Dashboard
## Status
Accepted — 2026-08-03
## Context
ARR Web login protects Finance operations, but the mobile H5 dashboard is a read-only aggregate view intended for
broader viewing. Making only the HTML page public would leave its data requests behind the login gate. Making generic
desktop APIs public would widen access to jobs, traces, operational health, filenames and other operator data.
## Decision
1. Publish the H5 page/assets anonymously.
2. Add purpose-built anonymous `GET /api/public/h5/months` and `GET /api/public/h5/analytics` routes.
3. Return only aggregate dashboard data and month/date coverage from those routes; omit source hashes, filenames,
traces, detailed health, source coordinates, guest/detail rows and operational metadata.
4. Keep desktop pages, generic and legacy APIs, jobs/traces, downloads, uploads, Booking/company/report operations and
mutations behind the existing server-side session/CSRF boundary.
5. Keep `/healthz` as the only public readiness signal; public JSON responses remain `no-store`.
## Consequences
- Anyone with the H5 URL can view the aggregate channel/room dashboard and all month options returned by the public H5
month index.
- Finance/operator workflows remain authenticated and the public H5 surface has no write capability.
- Deployment must treat the aggregate metrics, channel names and financial totals as intentionally public data and should
apply normal HTTPS, access logging and rate/abuse controls at the edge.

View File

@@ -4,6 +4,7 @@
| ID | Decision | Status | Date | Applies To | Detail |
|---|---|---|---|---|---|
| ADR-005 | 手机 H5 看板通过专用只读聚合接口公开访问;桌面及运营接口继续认证 | Accepted | 2026-08-03 | Web access boundary, H5, Channel BI | [ADR-005](ADR-005-public-read-only-h5-dashboard.md) |
| ADR-004 | ARR2.0 owns deterministic processing, artifact validation and terminal ingestion; no Agent/MCP in production XML flow | Accepted | 2026-07-30 | Upload, processing runtime, OSS ACL, validation, deployment | [ADR-004](ADR-004-arr-owned-programmatic-processing.md) |
| ADR-001 | 月报由独立 worker 自动触发;“更新至”取最新纳入的 `ARRIVAL`;发布后页面自动新增;`TOTAL PRICE` 为公式字段 | Implemented | 2026-07-29 | 月报触发、持久化、页面同步、XLSX 输出 | [ADR-001](ADR-001-automatic-monthly-trigger-and-total-price-formula.md) |