Hacktoberfest 2026: le issue che i maintainer hanno segnato per ottobre, aperte e adatte ai principianti. Sfoglia le issue Hacktoberfest

arch(domain): split the Incident aggregate and move German ETB wording and presentation types out of Domain

Aperta
#299 1 commento 0 reazioni 0 assegnatari Vedi su GitHub

I maintainer di solito rispondono entro 1 giorno

Nessuno ha ancora preso questa issue.

Valutazione

Difficoltà
5/5
Tempo stimato
Più di una settimana
Idoneità per principianti
35/100
Tipo di issue
Refactoring
Chiarezza
Abbastanza chiara
Stato di attività
Attiva
Stack tecnologico
android, csharp, sqlite
Ambito
backend, databases

Direzione di ricerca

Start with src/LageBuch.Domain/Incident.cs, especially Rehydrate, the feature areas, and the German text noted in the issue; also read Formatting.cs and IncidentPdfSections.cs and their comments. The proposal offers several architectural directions rather than a scoped change, so first agree on one direction with maintainers. Done means that agreed refactor is implemented while preserving the aggregate's invariants and the Android build constraints.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Descrizione

enhancement

From the 2026-09-09 architecture review of main (35d86e1). Not urgent; a direction for when the next feature lands in Incident.

Incident (src/LageBuch.Domain/Incident.cs) is 1 112 lines with about 45 public members across ten feature areas, a 22-parameter Rehydrate (:122) that mirrors the SQLite table set, and it composes German ETB text inside the aggregate (Label :615, StatusChangeText :666, and every AppendSystemEntry literal such as "Einsatz begonnen"). Exception messages are end-user German too (:86, :643). Formatting.cs (de-DE date formats, em-dash placeholder) and IncidentPdfSections.cs (PDF section flags) are presentation concerns living in Domain.

The domain is otherwise exemplary: zero references, private setters, IReadOnlyList everywhere, invariants via EnsureOpen.

Proposal

  • Split Incident into partial classes per feature area (Forces, Scba, CoMeasurement, Tasks, Files, Journal) with the shared guards in the core file; or extract sub-aggregates where the feature has its own invariants (CO measurement is a good first candidate).
  • Route system-entry wording through a small ISystemEntryText (or resource) so wording and locale are not Domain changes.
  • Replace the 22-parameter Rehydrate with a IncidentSnapshot-style record that both the repository and SnapshotMapper build.
  • Move Formatting and IncidentPdfSections to Documents/AppLogic once the Android build graph allows (the comment in IncidentPdfSections.cs explains why they are parked in Domain).
Lingua principale
C#
Stelle
1
Fork
3
Merge medio
4h 49m
PR unite (30g)
177

Preparare l'ambiente

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Altre issue di CodeForFire/lagebuch

Tutte le issue di CodeForFire/lagebuch

Issue simili

Altre issue su C#

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.