The static JS was orphaned at a prior backend refactor: it called
/registration-status, /register, /dashboard/summary, /dashboard/
transactions, /dashboard/analytics — none of which exist in views_api.
First render hit `Failed to check registration status` and the
"Welcome to DCA" form's submit failed with `Failed to register for DCA`.
This commit rewires the data layer to the v2 endpoints:
- GET /api/v1/dca-client/preferences (auto-onboards the LP on load
— the act of opening this dashboard is what creates the LP's
dca_lp row, which unlocks deposit creation on the operator side)
- GET /api/v1/dca-client/positions (404 → empty-state, not error)
- GET /api/v1/dca-client/transactions
The legacy "Welcome / register" wizard in index.html is now dead
(`isRegistered` defaults to true and `loadPreferences` always succeeds
because the backend auto-creates). The chart panel is also dead (no
backend /analytics endpoint). Stubs added for `registerClient`,
`loadChartData`, plus `chartLoading` / `chartTimeRange` /
`analyticsData` data fields so the template renders without
undefined-binding warnings even though those branches never execute.
Future cleanup: the registration card + chart panel HTML can be
deleted from the template, and a preferences-editor card (PUT
/preferences) added. Out of scope here — the priority was unblocking
E2E testing on v2-bitspire.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>