Repository navigation
feat(einsatzdaten): pre-fill the Einsatznummer from a Stammdaten format - #751
Merged
Merged
Conversation
DeepDiver1975
force-pushed
the
feat/462-einsatznummer-format
branch
2 times, most recently
from
October 25, 2026 22:18
02f149b to
88dab14
Compare
DeepDiver1975
force-pushed
the
feat/462-einsatznummer-format
branch
2 times, most recently
from
October 26, 2026 21:17
f348d6e to
feadd73
Compare
The Stammdaten take an Einsatznummer template such as
"B 1.2 {JJMMTT} {NNN}": {JJMMTT} (and JJJJ/JJ/MM/TT) is the incident's
start date, a run of N the gap for the Leitstelle's running number.
The Einsatzdaten dialog of an incident without a number opens with the
prefix and date typed in; tabbing into the field puts the caret on the
gap instead of selecting everything. The untouched pre-fill is never
stored, so SPEICHERN after only the Stichwort keeps the number empty and
ABBRECHEN closes without asking. A number of another shape is accepted
with a non-blocking hint.
The template is untrusted input (import, sync host), so it is trimmed
and capped, and matched by a hand-rolled linear matcher rather than a
regular expression built from it. The /masterdata payload gains an
optional settings key: ProtocolVersion 25, floor unchanged at 24.
Fixes #462
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Signed-off-by: Thomas Müller <1005065+DeepDiver1975@users.noreply.github.com>
…tichwort
The leading letter of a Bavarian Einsatznummer is the Einsatzart, not a
constant: B for Brand, R for Rettungsdienst ("R 1.2 YYMMDD XXXX"), and so
on. Only "1.2", the spec's version, is fixed.
A new {A} placeholder takes the Stichwort's first letter (B3P -> B,
THL 1 -> T, RD -> R). The Stichwort is usually typed in the same dialog,
so the pre-fill follows it while the number is still untouched, and
never once typed into. Without a Stichwort the letter is a gap and the
caret waits on it. The shape check reads it as one capital letter.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Signed-off-by: Thomas Müller <1005065+DeepDiver1975@users.noreply.github.com>
…able ones
Field report: "{A} 1.2 {LLMMTT} {NNNN}" was saved without a word, and
the Einsatzdaten dialog then pre-filled nothing, since L is no
placeholder letter.
The format field now names the problem under it and turns red while a
template cannot be read; saving is not refused, so it can be fixed
later. It is also a suggestion box offering the published formats,
Bayern's "{A} 1.2 {JJMMTT} {NNNN}" first, then Baden-Württemberg's
"{A} {JJMMTT} {NNN}" (Landesfeuerwehrschule F3 material) and the UCRI
Leitstellen-Schnittstelle's "{JJJJ}-{MM}-{TT}-{NNNN}". Any other
template stays typeable.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Signed-off-by: Thomas Müller <1005065+DeepDiver1975@users.noreply.github.com>
DeepDiver1975
force-pushed
the
feat/462-einsatznummer-format
branch
from
October 26, 2026 21:41
feadd73 to
a2ded18
Compare
Contributor
Author
|
Stammdaten editor follow-up (a2ded18), from a field report:
No published scheme turned up for NRW, Hessen or Niedersachsen. FeuerON (Niedersachsen) only has a field "Einsatznummer (Jahr)" with no example. Each is one example, not a standard, so the field stays free text. 🤖 Generated with Claude Code |
Each row of the format suggestions shows its label beside the template: Bayern, Baden-Württemberg, Leitstellen-Schnittstelle UCRI. Picking a row fills in the template alone. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Signed-off-by: Thomas Müller <1005065+DeepDiver1975@users.noreply.github.com>
Contributor
Author
|
The format suggestions now name where each is used: Bayern, Baden-Württemberg, Leitstellen-Schnittstelle UCRI. Picking a row fills in the template alone. 🤖 Generated with Claude Code |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.



Fixes #462
What
The Stammdaten → Einstellungen tab gets an Einsatznummer-Format, e.g.
{A} 1.2 {JJMMTT} {NNNN}:{A}is the Einsatzart, taken from the Stichwort's first letter:B3P→ B,THL 1→ T,ABC …→ A,SON …→ S,RD …→ R.1.2is the spec's version and stays literal.{JJMMTT}(also{JJJJ},{JJ},{MM},{TT}and theY/Dspellings) is the incident's start date.Nis the gap for the Leitstelle's running number. Nothing is counted locally.B for Brand and R for Rettungsdienst are confirmed by KBI Dachau, which gives
R 1.2 YYMMDD XXXX. Taking the first letter for THL, ABC and Sonstige is an inference from how the Bavarian Stichwörter are written.The EINSATZDATEN dialog of an incident that has no number yet opens with the known parts typed in:
The open questions from the issue, as decided:
How
IncidentNumberFormat(Domain) parses the template, builds the pre-fill and checks the shape. The template arrives from an import or a sync host, so the matcher is hand-rolled and linear rather than aRegexbuilt from untrusted text.IncidentSettings.IncidentNumberFormatis trimmed, blank → none, and capped at 60 characters. It is stored inmd_text_settings(no migration; cleared as""), and imported/exported assettings.incidentNumberFormat.docs/master-data.example.jsonis updated./masterdatagains an optional key.ProtocolVersion24 → 25 (rebased above main's 24), and the floor stays at 24.Screenshots
Before — EINSATZDATEN for an incident without a number (also what it looks like with no format configured):
After — Stichwort B3P, Tab into the number: the Brand letter and date are typed in, with the caret on the gap:
After —
THL 1typed into an empty dialog, then Tab: the number follows the Stichwort:After — a number of another shape shows the hint and still saves:
After — the new setting in Stammdaten → Einstellungen (no before shot rendered; the tab simply ended at Rückzugsdruck):
Verification
make clean ci: all 9 test assemblies pass.make format-checkpasses.make mutate SINCE=origin/main, score on changed lines: Domain 95.0 %, AppLogic 92.4 %, Persistence 95.2 %, Sync (no mutants on changed lines).Typing_the_stichwort_first_puts_its_einsatzart_in_front_of_the_numberruns the real order: typeTHL 1, Tab,77, Enter. It storesT 1.2 260622 77.🤖 Generated with Claude Code