BillTracker/client/components/data
null d53a64b604 feat(data): "Erase my data" danger zone (Batch 5)
New services/userDataService.js eraseUserData() permanently wipes a user's
financial + imported data in one transaction (child → parent order for FK
safety): bills (+ cascading payments/monthly_bill_state/bill_history_ranges),
transactions/accounts/data_sources, categories/groups, templates, snowball,
spending rules/budgets, merchant rules, imports, and per-user hint tables. It
PRESERVES the account, sessions, 2FA/WebAuthn, login history and preferences —
this resets your data, not your account — then re-seeds default categories and
writes an audit row to import_history.

- POST /api/user/erase-data — rate-limited (demoDataLimiter), requires a
  type-to-confirm token ("ERASE"), structured errors.
- UI: EraseDataSection danger-zone card (Export & backups pane) — red-accented,
  "download a backup first" nudge, type-to-confirm AlertDialog, toasts; on
  success DataPage reloads all state.

Tests: tests/eraseUserData.test.js — wipes user A only, preserves user B +
account + session, re-seeds categories, audited. Server 139 pass.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-07-03 15:21:07 -05:00
..
AutoMatchReview.jsx refactor(client): single source of truth for money formatting (IMP-CODE-01) 2026-07-03 12:46:22 -05:00
BankSyncSection.jsx refactor(client): single source of truth for money formatting (IMP-CODE-01) 2026-07-03 12:46:22 -05:00
ConnectionHero.jsx feat(data): actionable badges, health dots, at-a-glance stats, palette links (Batch 2) 2026-07-03 15:05:25 -05:00
DataNav.jsx feat(data): two-pane shell + connection hero + deep-linking (Batch 1) 2026-07-03 15:02:36 -05:00
DownloadMyDataSection.jsx feat(export): JSON export + date-range/format payments export (Batch 4) 2026-07-03 15:15:36 -05:00
EraseDataSection.jsx feat(data): "Erase my data" danger zone (Batch 5) 2026-07-03 15:21:07 -05:00
ImportHistorySection.jsx chore: bump to v0.34.2, subscription badge fix on Tracker rows 2026-05-30 21:52:02 -05:00
ImportMyDataSection.jsx chore: bump to v0.34.2, subscription badge fix on Tracker rows 2026-05-30 21:52:02 -05:00
ImportOfxSection.jsx feat(import): OFX/QFX transaction import (Batch 3) 2026-07-03 15:11:59 -05:00
ImportSpreadsheetSection.jsx 0.34.3 2026-05-31 15:06:10 -05:00
ImportTransactionCsvSection.jsx chore: bump to v0.34.2, subscription badge fix on Tracker rows 2026-05-30 21:52:02 -05:00
SeedDemoDataSection.jsx chore: bump to v0.34.2, subscription badge fix on Tracker rows 2026-05-30 21:52:02 -05:00
TransactionMatchingSection.jsx feat(banking): bank transactions page with merchant/store matching, transaction matching refactor, bank sync improvements (batch 0.40.0) 2026-06-14 15:15:31 -05:00
dataShared.jsx feat(data): modernize SectionCard chrome (Batch 0 — Data overhaul) 2026-07-03 14:57:03 -05:00