You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Chemicals web admin: W5 settings and digest preview - #1434
flutter-chemistry Plan E, PR E2 (rollout step 10): the Kemi web admin "Indstillinger" screen and the digest preview. Builds on PR E1 (#1430, merged).
What E2 delivers
Task 6, base package and TS port.Microting.EformBackendConfigurationBase 10.0.56 -> 10.0.57 (Plan D's ChemicalAlertRules), pinned by ChemicalAlertRulesAvailabilityTests. A TypeScript port of the rule (chemical-alert-rules.helper.ts) with Plan D's C1 vectors (thresholds, calendar-month clamping, severity, governing deadline).
Task 7, digest preview backend.GET api/backend-configuration-pn/chemicals/properties/{id}/digest-preview (ChemicalDigestController, first-user only until GA, TODO(chemistry-GA)). ChemicalDigestPreviewBuilder rebuilds Plan D's four sections for one property: open placements only, thresholds evaluated at the NEXT e-mail slot (Monday 07:00 Europe/Copenhagen), IsoWeek of that slot, new registrations since the most recent slot (moves excluded), Plan D's ordering (deadline date, then name; ordinal, case-insensitive), recipients read through Plan A's MapSettings. Typed outcomes are not sent to Sentry (ChemicalsController.FailureResult).
Task 8, W5 settings page and menu entry. "Ejendomsindstillinger - Kemi": stock toggle, digest recipients (e-mail chips, server-compatible validation), the four fixed thresholds of spec section 9, and the digest preview ("Naeste e-mail (uge N)"). Load/failed/saving states, unsaved-changes confirm and beforeunload shared with W4, preview failure state. New menu child "Indstillinger" (backend-configuration-pn-chemicals-settings, position 3) under the Kemi group; new Kemi i18n keys in all 26 locales.
Menu migration for existing tenants
PluginMenuSyncService (unchanged from E1) adds the new child at the next pod start: it is idempotent (keyed on the menu template E2EId), re-checks inside the transaction, only runs for an enabled plugin, and does not recreate a Kemi group an admin deleted. A tenant that got Kemi with "Rettigheder" in E1 gets "Indstillinger" under the existing group, once. The sync is one-shot: if it fails at startup, an admin can add the entry by hand (Advanced > Navigation menu). Admins other than the first user still get the "not available yet" notice.
…g C# vectors in the spec
Behaviour-neutral: pad as a function, requiresAction via actionSeverity,
adds the C# vector rows and the governingDeadline tie-break test.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_0122jmSDSB5HSHQK36Bnt5Wy
First-user gated (TODO chemistry-GA), Sentry only for unexpected failures,
ISO week of the next digest slot, recipients through MapSettings.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_0122jmSDSB5HSHQK36Bnt5Wy
… fixed old date
With UtcNow-30d the placements fell into the fixed Wednesday window from
2026-11-25.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_0122jmSDSB5HSHQK36Bnt5Wy
Pending recipient text is unsaved, superseded settings/preview responses
are ignored, mixed plain and named address paste keeps every address.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_0122jmSDSB5HSHQK36Bnt5Wy
Pending recipient text counts as unsaved; settings and preview answers
carry a request generation so superseded ones are ignored; a plain address
before a named one in a mixed paste is kept.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_0122jmSDSB5HSHQK36Bnt5Wy
The passed-deadline hint uses medical terms instead of a chemical inventory placement: curativo (dressing) in ptPT and ptBR, pleister (bandage) in nlNL, and implant/implantation terms in plPL, ltLT and huHU. The Portuguese and Dutch text also reads as an instruction to repeat a procedure. These hints should explain that deadline alerts repeat weekly until the chemical placement is removed. Correct this key in all six locales using consistent inventory terminology.
The stock toggle uses Chemicals: Disabled when stock management is off, but 13 locales translate disability rather than an inactive feature. Replace these values with software-state labels: ukUA: Вимкнено; svSE: Inaktiverad; roRO: Dezactivat; noNO: Deaktivert; nlNL: Uitgeschakeld; lvLV: Atspējots; ltLT: Išjungta; itIT: Disabilitato; huHU: Letiltva; fiFI: Ei käytössä; etET: Välja lülitatud; elGR: Απενεργοποιημένο; bgBG: Деактивирано. This makes the visible toggle label describe the actual setting.
After a user clears a rejected recipient draft and clicks Save, the input's blur handler clears invalidRecipients. Removing this row moves Save before the click completes, which can prevent the save. The new persistence test explicitly blurs first to avoid this layout shift, but the user-facing interaction is unchanged. Keep the validation layout stable during the click or change when validation updates the layout, and cover clicking Save directly after correcting the draft.
“Zmeny sa uložili” says the changes were saved, but this message appears after a failed save. The edits remain only in the form, not in persisted settings. Say that explicitly so users know they must retry.
This hint says warnings repeat until the location (“ubicación”) is removed. The ptBR and ptPT versions likewise say “localização”. The preview instead excludes closed chemical placements, not locations. Clarify that the product's placement must be removed: for example, “Se repite cada semana hasta que se retire la colocación del producto” in esES, and “até o registro de colocação do produto ser removido” (ptBR) / “até o registo de colocação do produto ser removido” (ptPT).
Correct Chemicals: Push translations to mean push notifications
The Chemicals: Push translations name pressing or physical pushing rather than push notifications. For example, German shows “Drücken”, French “Pousser”, and Portuguese “Empurrar”, obscuring the warning-delivery channel. Correct this key in bgBG, deDE, elGR, esES, etET, fiFI, frFR, hrHR, huHU, isIS, itIT, ltLT, lvLV, nlNL, noNO, plPL, ptBR, ptPT, roRO, slSL, svSE and ukUA. Use notification labels such as “Push-Benachrichtigungen”, “Notifications push” and “Notificações push”, and add focused translation-meaning coverage.
The switch's accessible name is only “Enabled” or “Disabled”; the adjacent “Stock management” heading is not associated with it. Screen-reader users navigating directly between controls cannot identify which setting it changes. Add the translated setting name to its accessible label while retaining the visible on/off text.
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
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.
flutter-chemistry Plan E, PR E2 (rollout step 10): the Kemi web admin "Indstillinger" screen and the digest preview. Builds on PR E1 (#1430, merged).
What E2 delivers
Microting.EformBackendConfigurationBase10.0.56 -> 10.0.57 (Plan D'sChemicalAlertRules), pinned byChemicalAlertRulesAvailabilityTests. A TypeScript port of the rule (chemical-alert-rules.helper.ts) with Plan D's C1 vectors (thresholds, calendar-month clamping, severity, governing deadline).GET api/backend-configuration-pn/chemicals/properties/{id}/digest-preview(ChemicalDigestController, first-user only until GA,TODO(chemistry-GA)).ChemicalDigestPreviewBuilderrebuilds Plan D's four sections for one property: open placements only, thresholds evaluated at the NEXT e-mail slot (Monday 07:00 Europe/Copenhagen),IsoWeekof that slot, new registrations since the most recent slot (moves excluded), Plan D's ordering (deadline date, then name; ordinal, case-insensitive), recipients read through Plan A'sMapSettings. Typed outcomes are not sent to Sentry (ChemicalsController.FailureResult).beforeunloadshared with W4, preview failure state. New menu child "Indstillinger" (backend-configuration-pn-chemicals-settings, position 3) under the Kemi group; new Kemi i18n keys in all 26 locales.Menu migration for existing tenants
PluginMenuSyncService(unchanged from E1) adds the new child at the next pod start: it is idempotent (keyed on the menu template E2EId), re-checks inside the transaction, only runs for an enabled plugin, and does not recreate a Kemi group an admin deleted. A tenant that got Kemi with "Rettigheder" in E1 gets "Indstillinger" under the existing group, once. The sync is one-shot: if it fails at startup, an admin can add the entry by hand (Advanced > Navigation menu). Admins other than the first user still get the "not available yet" notice.Tests
ChemicalDigestPreviewBuilderTests(sections, closed placements, moves, ordering, next-slot thresholds, ISO weeks incl. week 53 and DST),ChemicalDigestControllerTests(route/policy, gate, Sentry),ChemicalsMenuTests,PluginMenuSyncServiceTests(E1 -> E2 upgrade), registration tests.e/chemicals-settings.spec.ts(shard e).Red -> green CI runs (TDD via CI)
Parked (not in E2)
hasActionItemsis not asserted at the JSON boundary in the e2e; E3 will assert it when W1 seeds placements.🤖 Generated with Claude Code
https://claude.ai/code/session_0122jmSDSB5HSHQK36Bnt5Wy