From 36efc06d7fe9b0c0b8f25945fd989155fbcbed35 Mon Sep 17 00:00:00 2001
From: Cyber Preacher <72062250+Cyber-preacher@users.noreply.github.com>
Date: Wed, 19 Aug 2026 20:03:42 +0400
Subject: [PATCH 1/2] Clarify Court report routing choices
---
src/pages/courts/CourtReportCreate.tsx | 10 +++++---
.../courts/forms/CourtReportFormSections.tsx | 3 ++-
src/pages/courts/model/courtPresentation.ts | 25 +++++++++++++++++++
tests/unit/court-presentation.test.ts | 19 ++++++++++++++
4 files changed, 53 insertions(+), 4 deletions(-)
diff --git a/src/pages/courts/CourtReportCreate.tsx b/src/pages/courts/CourtReportCreate.tsx
index 840000a..1f4257f 100644
--- a/src/pages/courts/CourtReportCreate.tsx
+++ b/src/pages/courts/CourtReportCreate.tsx
@@ -47,7 +47,8 @@ import {
import {
courtLaneDisplay,
courtOffenseDisplay,
- courtStandingDisplay,
+ courtReportLaneChoiceLabel,
+ courtReportRouteDescription,
} from "./model/courtPresentation";
import {
courtErrorIssue,
@@ -499,7 +500,7 @@ const CourtReportCreate: React.FC = () => {
value={`${reason.offenseCode}:${reason.lane}`}
>
{courtOffenseDisplay(reason.offenseCode).label} ·{" "}
- {courtLaneDisplay(reason.lane).label}
+ {courtReportLaneChoiceLabel(reason.lane)}
))}
@@ -527,7 +528,10 @@ const CourtReportCreate: React.FC = () => {
direct={selectedReason.standing.directStanding}
source={selectedReason.standing.source}
/>
- {`. ${courtStandingDisplay(selectedReason.standing).description}`}
+ {`. ${courtReportRouteDescription(
+ selectedReason.reason.lane,
+ selectedReason.standing,
+ )}`}
>
) : capabilityLoading ? (
"The server is verifying the target, incident time, standing, and available lanes."
diff --git a/src/pages/courts/forms/CourtReportFormSections.tsx b/src/pages/courts/forms/CourtReportFormSections.tsx
index 5ae8e91..335a5f9 100644
--- a/src/pages/courts/forms/CourtReportFormSections.tsx
+++ b/src/pages/courts/forms/CourtReportFormSections.tsx
@@ -17,6 +17,7 @@ import {
import {
courtLaneDisplay,
courtOffenseDisplay,
+ courtReportRouteDescription,
} from "../model/courtPresentation";
import { courtEvidenceAccessLabel } from "./courtEvidence";
@@ -137,7 +138,7 @@ export function CourtReportReview({
- Population basis: {courtLabel(capability.population.basis)} ·{" "} - effective{" "} - {formatCourtInstant(capability.population.effectiveAt)}. -
+ {selectedReason ? ( ++ A community Court trigger is unavailable because fewer + than three eligible Governors remain after excluding the + respondent. +
+ ) + ) : ( ++ Governor population:{" "} + {capability.population.eligibleGovernorCount} ·{" "} + {courtLabel(capability.population.basis)} · effective{" "} + {formatCourtInstant(capability.population.effectiveAt)}. +
+ ) : null} +Next: {process.nextStep} @@ -492,7 +511,15 @@ const CourtReportDetail: React.FC = () => { onChange={(event) => setRespondentId(event.target.value) } + readOnly={Boolean(report.respondentId)} + required /> + {report.respondentId ? ( + + The respondent is fixed to the reported record and + cannot be changed by amendment. + + ) : null}