whisper-money/tests/Feature/Settings
Víctor Falcón e62f1d6aac
refactor(api): standardize serialization via model $hidden (#492)
## What

Standardizes how models are serialized across web, API, and Sync
responses by relying on Eloquent `$hidden` + accessors on the models
themselves, instead of ad-hoc `select` scopes and per-controller field
picking.

Touches 9 models (`Account`, `Bank`, `Budget`, `Category`, `Label`,
`LoanDetail`, `RealEstateDetail`, `Transaction`, plus pivot hiding) and
the controllers/middleware that consumed the old ad-hoc shapes.

## Why

- Single source of truth for response shape lives on the model, aligned
with Wayfinder model typegen.
- Removes duplicated field-selection logic scattered across controllers.
- Continues the duplication-removal PR series (#475–#483).

## How

- Hide internal columns and pivots via `$hidden`; expose computed fields
via accessors.
- Controllers return full models / load full relations rather than
hand-picked columns.
- `HandleInertiaRequests` slimmed down to match.

## Notes for reviewers

- Per-commit breakdown: each model standardized in its own commit for
easy review.
- Tests added/updated for each model to assert the serialized shape
(hidden columns absent, relations present).
- Full suite: 1382 passed / 1 skipped / 0 failed. `pint` clean.
2026-06-05 13:57:34 +02:00
..
AccountPageTest.php Reorganize setting items 2025-11-07 18:23:08 +00:00
AccountTest.php feat(currencies): add Colombian and Dominican peso (#471) 2026-06-01 18:14:16 +02:00
BankTest.php refactor(api): standardize serialization via model $hidden (#492) 2026-06-05 13:57:34 +02:00
BudgetSettingsRedirectTest.php fix(settings): restore budgets settings redirect (#228) 2026-03-16 13:04:08 +01:00
CategoryTest.php refactor(api): standardize serialization via model $hidden (#492) 2026-06-05 13:57:34 +02:00
CategoryTreeTest.php feat: parent/child category tree (#474) 2026-06-03 19:30:12 +02:00
ChartColorSchemeTest.php fix: route new PWA guests to signup (#313) 2026-04-21 10:53:05 +01:00
DeleteAccountPageTest.php Reorganize setting items 2025-11-07 18:23:08 +00:00
NetWorthChartLoanPreferenceTest.php fix: route new PWA guests to signup (#313) 2026-04-21 10:53:05 +01:00
NetWorthChartRealEstatePreferenceTest.php fix: route new PWA guests to signup (#313) 2026-04-21 10:53:05 +01:00
NotificationPreferenceTest.php feat(settings): let users disable bank transactions email (#472) 2026-06-02 12:24:39 +02:00
PasswordUpdateTest.php E2E Encryption 2025-11-07 14:21:25 +00:00
ProfileUpdateTest.php feat(currency): add Saudi Riyal (SAR) (#461) 2026-06-01 08:52:21 +02:00
TimezoneTest.php fix: route new PWA guests to signup (#313) 2026-04-21 10:53:05 +01:00
TwoFactorAuthenticationTest.php E2E Encryption 2025-11-07 14:21:25 +00:00