- Add JSONB pension_params column to retirement_configs
- Add data JSONB column to pension_entries
- Create pension calculator strategy classes (Base, DeGrv, UsSocialSecurity, UkStatePension, FrRegimeGeneral, EsSocialSecurity)
- Update RetirementConfig model to delegate to calculators
- Make PensionEntry.current_points optional for non-points systems
- Update controller strong params (pension_params: {})
- Add Stimulus pension_system_controller for dynamic form fields
- Update views with per-country field groups and conditional points columns
- Expand i18n (EN, DE) and add ES, FR locale files
- Update fixtures and tests for new schema
Addresses review feedback from jjmata on PR #1057
Introduces retirement and FIRE (Financial Independence, Retire Early)
planning as a new top-level feature in the sidebar navigation.
Key features:
- RetirementConfig model: stores retirement planning parameters per family
(birth year, retirement age, target income, pension system, etc.)
- PensionEntry model: tracks pension statements (Renteninformation) over time
with pension points, current/projected monthly pension
- German GRV pension calculations:
- Estimated monthly pension from Entgeltpunkte x Rentenwert
- After-tax pension estimation
- Monthly pension gap analysis
- FIRE calculations:
- FIRE number (capital needed via 4% rule, inflation-adjusted)
- FIRE progress percentage from current portfolio value
- Estimated FIRE date (iterative monthly projection)
- Required monthly savings to close pension gap
- Dashboard view with overview cards, FIRE progress bar, assumptions panel,
and pension history table with add/delete entries
- Setup and edit views for configuring retirement parameters
- Full i18n support (English + German)
- Minitest coverage for models and controller
Database: 2 new tables (retirement_configs, pension_entries) with UUID PKs
Routes: singular resource with setup, add/destroy pension entry actions
This is an initial implementation focused on the German GRV pension system.
The architecture supports extending to other pension systems (custom/other).
Open to suggestions and improvements from the community - contributions for
additional pension systems, visualization charts, or calculation refinements
are very welcome.