refactor(backend+frontend): contributionEuro -> contributionCents #237

Merged
niboer merged 2 commits from issue-217 into main 2026-07-05 21:02:37 +02:00
Owner

closes #217

EventGuest.contributionEuro (Decimal, Euro) -> contributionCents (Int, Cents)

  • Backend: Schema, Migration, Seed, Routes, openapi.yaml, Tests
  • Frontend: Orval-Regeneration, page.svelte, page.server.ts, Tests
  • Design-Dokument 02-datenmodell.md aktualisiert

Blockiert #16 (ZUGFeRD-Rechnungsmodul)

closes #217 EventGuest.contributionEuro (Decimal, Euro) -> contributionCents (Int, Cents) - Backend: Schema, Migration, Seed, Routes, openapi.yaml, Tests - Frontend: Orval-Regeneration, page.svelte, page.server.ts, Tests - Design-Dokument 02-datenmodell.md aktualisiert Blockiert #16 (ZUGFeRD-Rechnungsmodul)
refs #217

Aktuelles: EventGuest.contributionEuro speichert den Gastbeitrag als Decimal(10,2) in Euro.
Neu: EventGuest.contributionCents speichert den Gastbeitrag als Integer in Cent.

Aenderungen:
- Prisma-Schema: Feld-Rename + Typwechsel (Decimal -> Int)
- Migration 0001_full_schema: Spalte umbenannt + Typ geaendert
- Seed-Daten: Werte von Euro in Cent umgerechnet (125.00 -> 12500)
- forms.ts: serializeGuest aktualisiert, calculateContribution() gibt direkt Cents zurueck (kein /100 mehr)
- guests.ts: serializeGuest aktualisiert
- persons.ts: Feld-Rename in Invitation-Responses
- openapi.yaml: 3x Feld-Rename + Typ aendern (number/float -> integer/minimum: 0)
- Tests: Alle contributionEuro-Referenzen aktualisiert (Werte * 100)
- Design-Dokument 02-datenmodell.md aktualisiert (Beschreibung + Standardwert)
feat(frontend): contributionEuro -> contributionCents in UI und Tests
Some checks failed
CI Backend / lint-backend (pull_request) Successful in 52s
CI Frontend / lint-frontend (pull_request) Successful in 1m13s
CI Meta / conventional-commit (pull_request) Successful in 1s
E2E / e2e (pull_request) Failing after 4s
CI Backend / test-backend (pull_request) Successful in 1m44s
CI Frontend / test-frontend (pull_request) Successful in 42s
eb2e31ff64
closes #217

Aktuelles: Frontend verwendet contributionEuro (Euro) aus API.
Neu: Frontend verwendet contributionCents (Cents) aus API.

Aenderungen:
- generated.ts via Orval aus openapi.yaml regeneriert (contributionCents)
- +page.svelte: formatEuroCent() fuer Darstellung, /100 in Inline-Formatierung, Column-Keys aktualisiert
- +page.server.ts: Stats-Berechnung direkt mit Cents (kein Number()-Wrap mehr)
- formatEuro() entfernt (unused), formatEuroCent() bleibt
- Tests: Mock-Daten und Erwartungen auf Cent-Werte aktualisiert
niboer force-pushed issue-217 from eb2e31ff64
Some checks failed
CI Backend / lint-backend (pull_request) Successful in 52s
CI Frontend / lint-frontend (pull_request) Successful in 1m13s
CI Meta / conventional-commit (pull_request) Successful in 1s
E2E / e2e (pull_request) Failing after 4s
CI Backend / test-backend (pull_request) Successful in 1m44s
CI Frontend / test-frontend (pull_request) Successful in 42s
to 38e1616666
All checks were successful
CI Backend / lint-backend (pull_request) Successful in 51s
CI Frontend / lint-frontend (pull_request) Successful in 1m12s
CI Meta / conventional-commit (pull_request) Successful in 1s
E2E / e2e (pull_request) Successful in 3m47s
CI Backend / test-backend (pull_request) Successful in 1m44s
CI Frontend / test-frontend (pull_request) Successful in 44s
2026-07-05 20:53:25 +02:00
Compare
niboer merged commit 08081fbf6b into main 2026-07-05 21:02:37 +02:00
Sign in to join this conversation.
No description provided.