Skip to content

feat(einsatzdaten): add Hausnummer, PLZ and Ort to the address - #727

Merged
DeepDiver1975 merged 3 commits into
mainfrom
feat/401-address-fields
Oct 22, 2026
Merged

DeepDiver1975 merged 3 commits into
mainfrom
feat/401-address-fields

Conversation

@DeepDiver1975

@DeepDiver1975 DeepDiver1975 commented Oct 22, 2026 •

Copy link
Copy Markdown
Contributor

Summary

An incident's address held only Straße and Ortsteil. In überörtlicher Hilfe, or on a Landkreis-level ELW, there was nowhere to put the Ort, and the Hausnummer lived inside the street by convention. This PR adds Hausnummer, PLZ and Ort. All three are optional, so the one-Gemeinde workflow still needs only two fields. District (Ortsteil) stays its own field, as the issue proposes.

Fixes #401

Changes

  • Domain: Incident gains HouseNumber, PostalCode and Place. SetAddress takes them as optional trailing parameters, so existing two-argument callers keep their meaning.
  • Formatting: Formatting.Address joins the parts in German postal order — „Straße Hausnr., Ortsteil, PLZ Ort“ — and drops blank parts.
    • Today's two-field output (Hauptstr. 12, FFB) is unchanged.
    • A new Address(Incident) overload feeds the workspace header, the PDF header and the join prompt.
  • Persistence: migration V26 adds incident_meta.house_number, postal_code and place as nullable columns, declared in SchemaGuard.ExpectedColumns. A V25 file opens with them blank and its existing address intact (tested).
  • Sync: setAddress and IncidentSnapshot carry the new fields.
  • UI:
    • The Einsatzdaten dialog has two address rows: STRASSE | HAUSNR. and PLZ | ORT | ORTSTEIL.
    • The street placeholder no longer includes a house number.
    • The column ratios keep the PLZ box readable at phone width.

Screenshots

Before:

Before

After:

After

Checklist

  • Commits follow Conventional Commits and are DCO signed off (git commit -s)
  • Commits are cryptographically signed (SSH or GPG) and show as Verified on GitHub
  • dotnet build and dotnet test pass locally (make clean ci: 8/8 test assemblies green, 0 warnings; make format-check clean)
  • Changes under src/ add one changelog entry in changelog.d/
  • UI changes include before/after screenshots
  • No real master data / personnel data committed (screenshots use fictional data)

docs/samples/uebung.fwincident and the README screenshots are left for the milestone refresh, as usual.

🤖 Generated with Claude Code

An incident's location was Straße and Ortsteil only, so an Einsatz in
überörtlicher Hilfe had nowhere to put the Ort and the house number
lived inside the street by convention.

- Incident gains HouseNumber, PostalCode and Place; every part stays
  optional, so the one-Gemeinde workflow is unchanged.
- Formatting.Address joins "Straße Hausnr., Ortsteil, PLZ Ort" with
  blank parts dropped; the header, the PDF and the join prompt use it.
- Migration V26 adds the three incident_meta columns (declared in
  SchemaGuard); older files open with them blank.
- setAddress and the snapshot carry the new fields. A client at
  protocol 7 would send setAddress without them and clear what another
  device entered, so ProtocolVersion and MinimumProtocolVersion rise
  to 8.
- The Einsatzdaten dialog gets HAUSNR., PLZ and ORT fields.

Fixes #401

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Signed-off-by: Thomas Müller <1005065+DeepDiver1975@users.noreply.github.com>
SchemaGuard.Reconcile adds the same three nullable incident_meta
columns on every open, so no test can observe V26 being skipped or
mutated. CONTRIBUTING.md says to silence such mutants where they stand
with the reason rather than write a test for them.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Signed-off-by: Thomas Müller <1005065+DeepDiver1975@users.noreply.github.com>
The dialog screenshot kept the house number inside the street and paired
Ortsteil FFB with Fürstenfeldbruck; other fixtures paired Puch with
Petershausen. Every fixture and the ORT and PLZ placeholders now read
Hauptstr. 12, Puch, 82256 Fürstenfeldbruck, with the house number in
its own field.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Signed-off-by: Thomas Müller <1005065+DeepDiver1975@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

feat(einsatzdaten): the address model cannot hold a house number, PLZ or Ort

1 participant