Merged PR 2283: Data driven status pages from CRM

Related work items: #22805
This commit is contained in:
Robert Bond
2026-04-29 15:29:54 +00:00
parent 1fd192b870
commit baf5b1838d
20 changed files with 1079 additions and 42 deletions
+2
View File
@@ -255,6 +255,8 @@ function AppealsTab(props) {
className="govuk-link--no-underline"
onClick={() => {
setCurrentReference({
"statuscode":
item.statuscode,
"ticketnumber":
item.ticketnumber,
"currentReference":
+23 -35
View File
@@ -4,6 +4,7 @@ import { connect } from "react-redux";
import useTranslation from "next-translate/useTranslation";
import { formatDates } from "../utils";
import { useState } from "react";
import { getStagesForAppealType } from "./summary/utils/caseStagesByAppealType";
const statusClassMap = {
complete: "govuk-tag govuk-!-margin-top-2",
@@ -13,41 +14,19 @@ const statusClassMap = {
};
const statusTextMap = {
complete: "Complete",
"in-progress": "In progress",
"not-started": "Not started",
blocked: "Blocked"
complete: "status-complete",
"in-progress": "status-in-progress",
"not-started": "status-not-started",
blocked: "status-blocked"
};
const StatusDetails = (props) => {
let { t } = useTranslation();
const stages = [
{
id: "application-received",
title: "Application received",
status: "complete",
href: "#",
description:
"We have received the case and checked that the initial information has been provided."
},
{
id: "consultation",
title: "Consultation period",
status: "in-progress",
href: "#",
description:
"People can view the case documents and submit comments during this stage."
},
{
id: "decision",
title: "Decision",
status: "not-started",
href: "#",
description:
"The decision will be published once the case has been reviewed and completed."
}
];
const stages = getStagesForAppealType(
props.currentView?.caseReference?.appealType,
props.currentView?.caseReference?.statuscode
);
const EventView = (eventsArr) => {
eventsArr = eventsArr.value;
@@ -105,18 +84,22 @@ const StatusDetails = (props) => {
key={stage.id}
>
<div className="govuk-task-list__name-and-hint">
{stage.description && (
{stage.descriptionKey && (
<details
className="govuk-details govuk-!-margin-top-2 govuk-!-margin-bottom-2"
open={isOpen}
>
<summary className="govuk-details__summary">
<span className="govuk-details__summary-text">
{stage.title}
{t(
`case-stages:${stage.titleKey}`
)}
</span>
</summary>
<div className="govuk-details__text">
{stage.description}
{t(
`case-stages:${stage.descriptionKey}`
)}
</div>
</details>
)}
@@ -132,8 +115,13 @@ const StatusDetails = (props) => {
"govuk-tag govuk-tag--grey govuk-!-margin-top-2"
}
>
{statusTextMap[stage.status] ||
"Not started"}
{t(
`case-stages:${
statusTextMap[
stage.status
] || "status-not-started"
}`
)}
</strong>
</div>
</li>
@@ -0,0 +1,836 @@
const slugify = (value) =>
value
.toString()
.toLowerCase()
.replace(/[^a-z0-9]+/g, "-")
.replace(/^-|-$/g, "");
const buildStages = (stages) =>
stages.map((stage) => ({
id: slugify(stage.titleKey),
...stage
}));
export const stagesByCaseType = {
DNS: buildStages([
{
stageId: 846040001,
titleKey: "pre-application",
descriptionKey: "pre-application-desc"
},
{
stageId: 846040002,
titleKey: "environmental-impact-assessment-scoping",
descriptionKey: "environmental-impact-assessment-scoping-desc"
},
{
stageId: 846040003,
titleKey: "notification",
descriptionKey: "notification-desc"
},
{
stageId: 846040004,
titleKey: "acceptance-checking",
descriptionKey: "acceptance-checking-desc"
},
{
stageId: 846040005,
titleKey: "invalid-submission",
descriptionKey: "invalid-submission-desc"
},
{
stageId: 846040006,
titleKey: "consultation",
descriptionKey: "consultation-desc"
},
{
stageId: 846040007,
titleKey: "re-consultation",
descriptionKey: "re-consultation-desc"
},
{
stageId: 846040008,
titleKey: "reporting",
descriptionKey: "reporting-desc"
},
{
stageId: 846040009,
titleKey: "inspectors-decision",
descriptionKey: "inspectors-decision-desc"
},
{
stageId: 846040011,
titleKey: "report-to-ministers",
descriptionKey: "report-to-ministers-desc"
},
{
stageId: 846040012,
titleKey: "minister-s-decision",
descriptionKey: "minister-s-decision-desc"
},
{
stageId: 846040013,
titleKey: "case-closed",
descriptionKey: "case-closed-desc"
}
]),
SIP: "DNS",
PLANNING_S78: buildStages([
{
stageId: 846040014,
titleKey: "appeal-submitted",
descriptionKey: "appeal-submitted-desc"
},
{
stageId: 846040015,
titleKey: "appeal-registered",
descriptionKey: "appeal-registered-desc"
},
{
stageId: 846040016,
titleKey: "appeal-validated",
descriptionKey: "appeal-validated-desc"
},
{
stageId: 1,
titleKey: "case-in-progress",
descriptionKey: "case-in-progress-desc"
},
{
stageId: 846040017,
titleKey: "questionnaire-lpa-to-notify",
descriptionKey: "questionnaire-lpa-to-notify-desc"
},
{
stageId: 846040018,
titleKey: "representations-period",
descriptionKey: "representations-period-desc"
},
{
stageId: 846040019,
titleKey: "final-comments",
descriptionKey: "final-comments-desc"
},
{
stageId: 846040020,
titleKey: "event",
descriptionKey: "event-desc"
},
{
stageId: 846040021,
titleKey: "site-visit",
descriptionKey: "site-visit-desc"
},
{
stageId: 846040022,
titleKey: "decision-issued",
descriptionKey: "decision-issued-desc"
},
{
stageId: 846040013,
titleKey: "case-closed",
descriptionKey: "case-closed-desc"
}
]),
CONDITIONS_73_79: "PLANNING_S78",
LBCAC: "PLANNING_S78",
LDCS: "PLANNING_S78",
PLANNING_OBLIGATIONS_S106: "PLANNING_S78",
PRIOR_NOTIFICATION: "PLANNING_S78",
HAS: buildStages([
{
stageId: 846040014,
titleKey: "appeal-submitted",
descriptionKey: "appeal-submitted-desc"
},
{
stageId: 846040015,
titleKey: "appeal-registered",
descriptionKey: "appeal-registered-desc"
},
{
stageId: 846040016,
titleKey: "appeal-validated",
descriptionKey: "appeal-validated-desc"
},
{
stageId: 1,
titleKey: "case-in-progress",
descriptionKey: "case-in-progress-desc"
},
{
stageId: 846040021,
titleKey: "site-visit",
descriptionKey: "site-visit-desc"
},
{
stageId: 846040022,
titleKey: "decision-issued",
descriptionKey: "decision-issued-desc"
},
{
stageId: 846040013,
titleKey: "case-closed",
descriptionKey: "case-closed-desc"
}
]),
CALL_INS: buildStages([
{
stageId: 846040023,
titleKey: "application-called-in",
descriptionKey: "application-called-in-desc"
},
{
stageId: 846040043,
titleKey: "application-registered",
descriptionKey: "application-registered-desc"
},
{
stageId: 846040024,
titleKey: "application-validated",
descriptionKey: "application-validated-desc"
},
{
stageId: 1,
titleKey: "case-in-progress",
descriptionKey: "case-in-progress-desc"
},
{
stageId: 846040025,
titleKey: "lpa-to-notify",
descriptionKey: "lpa-to-notify-desc"
},
{
stageId: 846040026,
titleKey: "representations-period",
descriptionKey: "representations-period-desc"
},
{
stageId: 846040019,
titleKey: "final-comments",
descriptionKey: "final-comments-desc"
},
{
stageId: 846040020,
titleKey: "event",
descriptionKey: "event-desc"
},
{
stageId: 846040021,
titleKey: "site-visit",
descriptionKey: "site-visit-desc"
},
{
stageId: 846040028,
titleKey: "report-issued-to-welsh-ministers",
descriptionKey: "report-issued-to-welsh-ministers-desc"
},
{
stageId: 846040012,
titleKey: "minister-s-decision",
descriptionKey: "minister-s-decision-desc"
},
{
stageId: 846040013,
titleKey: "case-closed",
descriptionKey: "case-closed-desc"
}
]),
ENFORCEMENT: buildStages([
{
stageId: 846040014,
titleKey: "appeal-submitted",
descriptionKey: "appeal-submitted-desc"
},
{
stageId: 846040015,
titleKey: "appeal-registered",
descriptionKey: "appeal-registered-desc"
},
{
stageId: 846040029,
titleKey: "fee-due",
descriptionKey: "fee-due-desc"
},
{
stageId: 846040030,
titleKey: "validated",
descriptionKey: "appeal-validated-desc"
},
{
stageId: 1,
titleKey: "case-in-progress",
descriptionKey: "case-in-progress-desc"
},
{
stageId: 846040017,
titleKey: "questionnaire-lpa-to-notify",
descriptionKey: "questionnaire-lpa-to-notify-desc"
},
{
stageId: 846040018,
titleKey: "representations-period",
descriptionKey: "representations-period-desc"
},
{
stageId: 846040019,
titleKey: "final-comments",
descriptionKey: "final-comments-desc"
},
{
stageId: 846040020,
titleKey: "event",
descriptionKey: "event-desc"
},
{
stageId: 846040021,
titleKey: "site-visit",
descriptionKey: "site-visit-desc"
},
{
stageId: 846040022,
titleKey: "decision-issued",
descriptionKey: "decision-issued-desc"
},
{
stageId: 846040013,
titleKey: "case-closed",
descriptionKey: "case-closed-desc"
}
]),
ENFORCEMENT_LISTED_BUILDING: "ENFORCEMENT",
MAINTENANCE_OF_LAND: "ENFORCEMENT",
RIGHTS_OF_WAY_SCHEDULE_14: buildStages([
{
stageId: 846040014,
titleKey: "appeal-submitted",
descriptionKey: "appeal-submitted-desc"
},
{
stageId: 846040015,
titleKey: "appeal-registered",
descriptionKey: "appeal-registered-desc"
},
{
stageId: 846040016,
titleKey: "appeal-validated",
descriptionKey: "appeal-validated-desc"
},
{
stageId: 846040031,
titleKey: "appeal-start-case-in-progress",
descriptionKey: "case-in-progress-desc"
},
{
stageId: 846040032,
titleKey: "statements-representations-period",
descriptionKey: "statements-representations-period-desc"
},
{
stageId: 846040019,
titleKey: "final-comments",
descriptionKey: "final-comments-desc"
},
{
stageId: 846040021,
titleKey: "site-visit",
descriptionKey: "site-visit-desc"
},
{
stageId: 846040022,
titleKey: "decision-issued",
descriptionKey: "decision-issued-desc"
},
{
stageId: 846040013,
titleKey: "case-closed",
descriptionKey: "case-closed-desc"
}
]),
RIGHTS_OF_WAY_ORDERS: buildStages([
{
stageId: 846040033,
titleKey: "order-submitted",
descriptionKey: "order-submitted-desc"
},
{
stageId: 846040034,
titleKey: "order-submission-registered",
descriptionKey: "order-submission-registered-desc"
},
{
stageId: 846040035,
titleKey: "order-submission-validated",
descriptionKey: "order-submission-validated-desc"
},
{
stageId: 846040036,
titleKey: "case-started-case-in-progress",
descriptionKey: "case-started-case-in-progress-desc"
},
{
stageId: 846040010,
titleKey: "statements",
descriptionKey: "statements-desc"
},
{
stageId: 846040019,
titleKey: "final-comments",
descriptionKey: "final-comments-desc"
},
{
stageId: 846040037,
titleKey: "event-site-visit",
descriptionKey: "event-site-visit-desc"
},
{
stageId: 846040022,
titleKey: "decision-issued",
descriptionKey: "decision-issued-desc"
},
{
stageId: 846040013,
titleKey: "case-closed",
descriptionKey: "case-closed-desc"
}
]),
REQUESTS_FOR_DIRECTION: buildStages([
{
stageId: 846040042,
titleKey: "application-submitted",
descriptionKey: "application-submitted-desc"
},
{
stageId: 846040043,
titleKey: "application-registered",
descriptionKey: "application-registered-desc"
},
{
stageId: 846040036,
titleKey: "application-start-case-in-progress",
descriptionKey: "application-start-case-in-progress-desc"
},
{
stageId: 846040010,
titleKey: "statements",
descriptionKey: "statements-desc"
},
{
stageId: 846040019,
titleKey: "final-comments",
descriptionKey: "statements-desc"
},
{
stageId: 846040022,
titleKey: "decision-issued",
descriptionKey: "decision-issued-desc"
},
{
stageId: 846040013,
titleKey: "case-closed",
descriptionKey: "case-closed-desc"
}
]),
ADVERTS: buildStages([
{
stageId: 846040014,
titleKey: "appeal-submitted",
descriptionKey: "appeal-submitted-desc"
},
{
stageId: 846040015,
titleKey: "appeal-registered",
descriptionKey: "appeal-registered-desc"
},
{
stageId: 846040016,
titleKey: "appeal-validated",
descriptionKey: "appeal-validated-desc"
},
{
stageId: 1,
titleKey: "case-started-case-in-progress",
descriptionKey: "case-in-progress-desc"
},
{
stageId: 846040017,
titleKey: "questionnaire-lpa-to-notify",
descriptionKey: "questionnaire-lpa-to-notify-desc"
},
{
stageId: 846040010,
titleKey: "statements",
descriptionKey: "statements-desc"
},
{
stageId: 846040019,
titleKey: "final-comments",
descriptionKey: "final-comments-desc"
},
{
stageId: 846040021,
titleKey: "site-visit",
descriptionKey: "site-visit-desc"
},
{
stageId: 846040022,
titleKey: "decision-issued",
descriptionKey: "decision-issued-desc"
},
{
stageId: 846040013,
titleKey: "case-closed",
descriptionKey: "case-closed-desc"
}
]),
HEDGEROW_TPO: buildStages([
{
stageId: 846040014,
titleKey: "appeal-submitted",
descriptionKey: "appeal-submitted-desc"
},
{
stageId: 846040015,
titleKey: "appeal-registered",
descriptionKey: "appeal-registered-desc"
},
{
stageId: 846040016,
titleKey: "appeal-validated",
descriptionKey: "appeal-validated-desc"
},
{
stageId: 846040031,
titleKey: "appeal-start-case-in-progress",
descriptionKey: "case-in-progress-desc"
},
{
stageId: 846040017,
titleKey: "questionnaire-lpa-to-notify",
descriptionKey: "questionnaire-lpa-to-notify-desc"
},
{
stageId: 846040032,
titleKey: "statements-representations-period",
descriptionKey: "statements-representations-period-desc"
},
{
stageId: 846040019,
titleKey: "final-comments",
descriptionKey: "final-comments-desc"
},
{
stageId: 846040021,
titleKey: "site-visit",
descriptionKey: "site-visit-desc"
},
{
stageId: 846040022,
titleKey: "decision-issued",
descriptionKey: "decision-issued-desc"
},
{
stageId: 846040013,
titleKey: "case-closed",
descriptionKey: "case-closed-desc"
}
]),
COMMON_LAND: buildStages([
{
stageId: 846040042,
titleKey: "application-submitted",
descriptionKey: "application-submitted-desc"
},
{
stageId: 846040043,
titleKey: "application-registered",
descriptionKey: "application-registered-desc"
},
{
stageId: 846040024,
titleKey: "application-validated",
descriptionKey: "application-validated-desc"
},
{
stageId: 1,
titleKey: "application-start-case-in-progress",
descriptionKey: "application-start-case-in-progress-desc"
},
{
stageId: 846040038,
titleKey: "applicant-statement-on-representations",
descriptionKey: "applicant-statement-on-representations-desc"
},
{
stageId: 846040039,
titleKey: "representatives-comment",
descriptionKey: "representatives-comment-desc"
},
{
stageId: 846040027,
titleKey: "applicants-final-comment",
descriptionKey: "applicants-final-comment-desc"
},
{
stageId: 846040037,
titleKey: "event-site-visit",
descriptionKey: "event-site-visit-desc"
},
{
stageId: 846040022,
titleKey: "decision-issued",
descriptionKey: "decision-issued-desc"
},
{
stageId: 846040013,
titleKey: "case-closed",
descriptionKey: "case-closed-desc"
}
]),
COMPULSORY_PURCHASE_ORDERS: buildStages([
{
stageId: 846040033,
titleKey: "order-submitted",
descriptionKey: "order-submitted-desc"
},
{
stageId: 846040040,
titleKey: "order-registered",
descriptionKey: "order-submission-registered-desc"
},
{
stageId: 846040041,
titleKey: "order-validated",
descriptionKey: "order-submission-validated-desc"
},
{
stageId: 1,
titleKey: "case-in-progress",
descriptionKey: "case-started-case-in-progress-desc"
},
{
stageId: 846040010,
titleKey: "statements",
descriptionKey: "statements-desc"
},
{
stageId: 846040019,
titleKey: "final-comments",
descriptionKey: "final-comments-desc"
},
{
stageId: 846040037,
titleKey: "event-site-visit",
descriptionKey: "event-site-visit-desc"
},
{
stageId: 846040011,
titleKey: "report-to-ministers",
descriptionKey: "report-to-ministers-desc"
},
{
stageId: 846040013,
titleKey: "case-closed",
descriptionKey: "case-closed-desc"
}
]),
ELECTRICITY_ACT: "PLANNING_S78",
HARBOUR_REVISION_ORDER: "COMPULSORY_PURCHASE_ORDERS",
TRANSPORT_WORKS: "PLANNING_S78",
WAYLEAVE: buildStages([
{
stageId: 846040042,
titleKey: "application-submitted",
descriptionKey: "application-submitted-desc"
},
{
stageId: 846040043,
titleKey: "application-registered",
descriptionKey: "application-registered-desc"
},
{
stageId: 846040024,
titleKey: "application-validated",
descriptionKey: "application-validated-desc"
},
{
stageId: 1,
titleKey: "case-in-progress",
descriptionKey: "application-start-case-in-progress-desc"
},
{
stageId: 846040021,
titleKey: "site-visit",
descriptionKey: "site-visit-desc"
},
{
stageId: 846040044,
titleKey: "report-to-desnz",
descriptionKey: "report-to-desnz-desc"
},
{
stageId: 846040013,
titleKey: "case-closed",
descriptionKey: "case-closed-desc"
}
]),
NON_VALIDATION: buildStages([
{
stageId: 846040014,
titleKey: "appeal-submitted",
descriptionKey: "appeal-submitted-desc"
},
{
stageId: 846040015,
titleKey: "appeal-registered",
descriptionKey: "appeal-registered-desc"
},
{
stageId: 846040016,
titleKey: "appeal-validated",
descriptionKey: "appeal-validated-desc"
},
{
stageId: 1,
titleKey: "case-in-progress-assessment",
descriptionKey: "case-in-progress-desc"
},
{
stageId: 846040022,
titleKey: "decision-outcome",
descriptionKey: "decision-outcome-desc"
},
{
stageId: 846040013,
titleKey: "case-closed",
descriptionKey: "case-closed-desc"
}
])
};
export const caseTypeAliases = {
// Planning S78 group
S78: "PLANNING_S78",
PLANNING_78: "PLANNING_S78",
PLANNING_S78: "PLANNING_S78",
CONDITIONS_73_79: "CONDITIONS_73_79",
LBCAC: "LBCAC",
LDCS: "LDCS",
PLANNING_OBLIGATIONS_S106: "PLANNING_OBLIGATIONS_S106",
PRIOR_NOTIFICATION: "PRIOR_NOTIFICATION",
// Other types
HAS: "HAS",
CALL_INS: "CALL_INS",
CALL_IN: "CALL_INS",
ENFORCEMENT: "ENFORCEMENT",
ENFORCEMENT_LISTED_BUILDING: "ENFORCEMENT_LISTED_BUILDING",
MAINTENANCE_OF_LAND: "MAINTENANCE_OF_LAND",
RIGHTS_OF_WAY_SCHEDULE_14: "RIGHTS_OF_WAY_SCHEDULE_14",
RIGHTS_OF_WAY_ORDERS: "RIGHTS_OF_WAY_ORDERS",
REQUESTS_FOR_DIRECTION: "REQUESTS_FOR_DIRECTION",
ADVERTS: "ADVERTS",
HEDGEROW_TPO: "HEDGEROW_TPO",
COMMON_LAND: "COMMON_LAND",
COMPULSORY_PURCHASE_ORDERS: "COMPULSORY_PURCHASE_ORDERS",
ELECTRICITY_ACT: "ELECTRICITY_ACT",
HARBOUR_REVISION_ORDER: "HARBOUR_REVISION_ORDER",
TRANSPORT_WORKS: "TRANSPORT_WORKS",
WAYLEAVE: "WAYLEAVE",
NON_VALIDATION: "NON_VALIDATION",
DNS: "DNS",
SIP: "SIP"
};
const normaliseCaseType = (caseType) =>
caseType
?.toString()
.trim()
.toUpperCase()
.replace(/&/g, "AND")
.replace(/[^A-Z0-9]+/g, "_")
.replace(/^_|_$/g, "");
const resolveStages = (caseTypeOrAppealTypeId) => {
const appealTypeKey =
caseTypeKeyByAppealTypeId[Number(caseTypeOrAppealTypeId)];
const normalised = normaliseCaseType(caseTypeOrAppealTypeId);
const key = appealTypeKey || caseTypeAliases[normalised] || normalised;
const entry = stagesByCaseType[key];
if (!entry) return [];
if (typeof entry === "string") {
return stagesByCaseType[entry] || [];
}
return entry;
};
export const getStagesForAppealType = (caseType, currentStageId) => {
const stages = resolveStages(caseType);
const currentStageNumber = Number(currentStageId);
const currentIndex = stages.findIndex(
(stage) => Number(stage.stageId) === currentStageNumber
);
return stages.map((stage, index) => ({
...stage,
status:
currentIndex === -1
? "not-started"
: index < currentIndex
? "complete"
: index === currentIndex
? "in-progress"
: "not-started"
}));
};
export const caseTypeKeyByAppealTypeId = {
846040000: "PLANNING_S78",
846040001: "CONDITIONS_73_79",
846040002: "SIP",
846040003: "PLANNING_OBLIGATIONS_S106",
846040004: "HAS",
846040005: "ENFORCEMENT",
846040006: "ENFORCEMENT_LISTED_BUILDING",
846040007: "MAINTENANCE_OF_LAND",
846040008: "LDCS",
846040009: "PLANNING_S78",
846040010: "CALL_INS",
846040011: "DNS",
846040012: "ELECTRICITY_ACT",
846040013: "TRANSPORT_WORKS",
846040014: "HARBOUR_REVISION_ORDER",
846040015: "RIGHTS_OF_WAY_SCHEDULE_14",
846040016: "COMMON_LAND",
846040017: "HEDGEROW_TPO",
846040018: "ADVERTS",
846040019: "COMPULSORY_PURCHASE_ORDERS",
846040020: "PLANNING_S78",
846040021: "WAYLEAVE",
846040024: "NON_VALIDATION",
846040025: "LBCAC"
};
+2
View File
@@ -314,6 +314,8 @@ const TopThree = (props) => {
]
),
setCurrentReference({
"statuscode":
showTopThreeArr[key].statuscode,
"ticketnumber":
showTopThreeArr[key]
.ticketnumber,
+2
View File
@@ -218,6 +218,8 @@ const TopThree = (props) => {
data-id={index}
onClick={() => {
setCurrentReference({
"statuscode":
showTopThreeArr[key].statuscode,
"ticketnumber":
showTopThreeArr[key].ticketnumber,
"currentReference":
+1
View File
@@ -286,6 +286,7 @@ const ViewAllResults = (props) => {
}
setCurrentReference({
"statuscode": item.statuscode,
ticketnumber: item.ticketnumber,
currentReference: getCurrentReference(item),
currentType: currentViewKey,
+2
View File
@@ -439,6 +439,8 @@ const DNSSearchResults = (props) => {
className="govuk-link--no-underline"
onClick={() => {
setCurrentReference({
"statuscode":
item.statuscode,
"ticketnumber":
item.ticketnumber,
"currentReference":
+2
View File
@@ -422,6 +422,8 @@ const SearchResults = (props) => {
}
),
setCurrentReference({
"statuscode":
item.statuscode,
"ticketnumber":
item.ticketnumber,
"currentReference":
+4 -4
View File
@@ -21,8 +21,8 @@ module.exports = {
"/myportal/advancedsearch": ["search", "myportal"],
"/myportal/advancedsearchresults": ["search", "myportal", "case"],
"/myportal/searchresults": ["search", "myportal", "case"],
"/myportal/case": ["case"],
"/myportal/case/[ticketnumber]": ["case", "myportal"],
"/myportal/case": ["case", "home", "case-stages"],
"/myportal/case/[ticketnumber]": ["case", "myportal", "case-stages"],
"/myportal/dnsapplications": [
"search",
"dnsCommon",
@@ -43,9 +43,9 @@ module.exports = {
"/addresssearch": ["search", "case", "myportal"],
"/addresssearchresults": ["search", "case", "myportal"],
"/viewall": ["search"],
"/case": ["case", "home"],
"/case": ["case", "home", "case-stages"],
"/case/*": ["case", "home"],
"/case/[ticketnumber]": ["case", "home"],
"/case/[ticketnumber]": ["case", "home", "case-stages"],
"/case/id/[incident]": ["case", "home"],
"/myportal/representation": [
"case",
+3
View File
@@ -166,6 +166,7 @@ export const loadExistingRepresentation = async ({ store, ctx, bootstrap }) => {
store.dispatch(
setCurrentReference({
"statuscode": result.statuscode,
"ticketnumber":
result.ticketnumber || result.caseRef || result.pinswg_name,
"currentReference": result.caseRef,
@@ -223,6 +224,8 @@ export const loadNewRepresentation = async ({ store, ctx, bootstrap }) => {
store.dispatch(
setCurrentReference({
"statuscode": searchResultsObj.value[0].statuscode,
"isNRW":
accountDetails.emailaddress1.includes(process.env.NRWDOMAIN) ||
false,
+94
View File
@@ -0,0 +1,94 @@
{
"pre-application": "Cyn-ymgeisio",
"pre-application-desc": "Mae'r prosiect hwn yn y cyfnod cyn-ymgeisio ac nid yw wedi'i gyflwyno i PEDW i'w ystyried. Nid yw PEDW yn derbyn sylwadau ar hyn o bryd. Dylid cyfeirio unrhyw ymholiadau at yr ymgeisydd.",
"environmental-impact-assessment-scoping": "Cwmpasu Asesiad Effaith Amgylcheddol",
"environmental-impact-assessment-scoping-desc": "Penderfynu cwmpas y Datganiad Amgylcheddol yn y dyfodol. Dim ond cyflwyniadau am gwmpas arfaethedig y Datganiad Amgylcheddol y bydd PEDW yn eu hystyried ar hyn o bryd.",
"notification": "Hysbysiad",
"notification-desc": "Mae PEDW wedi cael gwybod gan yr ymgeisydd am eu bwriad i gyflwyno cais. Nid yw PEDW yn derbyn sylwadau ar hyn o bryd.",
"acceptance-checking": "Gwirio Derbyniad",
"acceptance-checking-desc": "Mae'r cais wedi'i gyflwyno i PEDW ac mae'n cael ei ddilysu ar hyn o bryd.",
"invalid-submission": "Cyflwyniad Annilys",
"invalid-submission-desc": "Mae'r cais a gyflwynwyd i PEDW wedi'i ganfod yn annilys ac mae angen rhagor o wybodaeth.",
"consultation": "Ymgynghori",
"consultation-desc": "Mae ymgynghoriad ar agor ar y cais hwn. Gellir cyflwyno sylwadau i PEDW yn ystod y cyfnod hwn.",
"re-consultation": "Ail-Ymgynghori",
"re-consultation-desc": "Mae PEDW yn ail-ymgynghori ar y cais hwn. Derbynnir sylwadau ar faterion cyfyngedig yn ystod y cyfnod ymgynghori.",
"reporting": "Adrodd",
"reporting-desc": "Mae'r Arolygydd yn ystyried y dystiolaeth a gyflwynwyd ar gyfer y cais hwn.",
"inspectors-decision": "Penderfyniad yr Arolygydd(ion)",
"inspectors-decision-desc": "Mae'r Arolygydd wedi cyhoeddi ei benderfyniad ar y cais hwn.",
"report-to-ministers": "Adrodd i Weinidogion",
"report-to-ministers-desc": "Mae'r Arolygydd wedi cyflwyno ei adroddiad i Weinidogion Cymru.",
"minister-s-decision": "Penderfyniad y Gweinidog",
"minister-s-decision-desc": "Bydd Gweinidogion Cymru yn cyhoeddi eu penderfyniad.",
"case-closed": "Achos wedi'i Gau",
"case-closed-desc": "Mae PEDW wedi penderfynu ar y cais ac mae'r achos bellach wedi'i gau.",
"appeal-submitted": "Apêl wedi'i Chyflwyno",
"appeal-submitted-desc": "Mae PEDW wedi derbyn yr apêl.",
"appeal-registered": "Apêl wedi'i Chofrestru",
"appeal-registered-desc": "Mae PEDW wedi cofrestru'r apêl.",
"appeal-validated": "Apêl wedi'i Dilysu",
"case-in-progress": "Achos ar y Gweill",
"case-in-progress-desc": "Mae'r cais a alwyd i mewn wedi'i gychwyn.",
"questionnaire-lpa-to-notify": "Holiadur / ACLl i'w Hysbysu",
"questionnaire-lpa-to-notify-desc": "Rhaid i'r Awdurdod Cynllunio Lleol gyflwyno eu Holiadur i PEDW a hysbysu partïon â diddordeb o ddechrau'r apêl, a'u cyfle i gyflwyno sylwadau.",
"representations-period": "Cyfnod y Sylwadau",
"representations-period-desc": "Gellir cyflwyno sylwadau nawr ar gyfer y cais a alwyd i mewn.",
"final-comments": "Sylwadau Terfynol",
"final-comments-desc": "Gellir cyflwyno sylwadau terfynol nawr ar gyfer y gorchymyn.",
"event": "Digwyddiad?",
"event-desc": "Mae PEDW yn trefnu'r digwyddiad Gwrandawiad / Ymchwiliad ar gyfer y cais a alwyd i mewn hwn.",
"site-visit": "Ymweliad â Safle",
"site-visit-desc": "Mae'r Arolygydd yn cynnal ei ymweliad â'r safle.",
"decision-issued": "Penderfyniad Wedi'i Gyhoeddi",
"decision-issued-desc": "Mae'r Arolygydd wedi cyflwyno ei benderfyniad i'w gyhoeddi.",
"application-called-in": "Cais Wedi'i Alw I Mewn",
"application-called-in-desc": "Mae'r cais wedi'i alw i mewn gan Weinidogion Cymru.",
"application-registered": "Cais Wedi'i Gofrestru",
"application-registered-desc": "Mae'r cais wedi'i gofrestru gan PEDW.",
"application-validated": "Cais Wedi'i Ddilysu",
"application-validated-desc": "Mae PEDW wedi canfod bod y cais yn ddilys.",
"lpa-to-notify": "ACLl i Hysbysu",
"lpa-to-notify-desc": "Rhaid i'r Awdurdod Cynllunio Lleol hysbysu partïon â diddordeb o ddechrau'r cais a alwyd i mewn, a'u cyfle i gyflwyno sylwadau.",
"report-issued-to-welsh-ministers": "Adroddiad Wedi'i Gyhoeddi i Weinidogion Cymru",
"report-issued-to-welsh-ministers-desc": "Mae'r Arolygydd wedi cyflwyno ei adroddiad argymhelliad i Weinidogion Cymru.",
"fee-due": "Ffi Ddyledus",
"fee-due-desc": "Os oes angen, mae'r ffi bellach yn ddyledus.",
"validated": "Wedi'i ddilysu",
"appeal-start-case-in-progress": "Dechrau Apêl / Achos ar y Gweill",
"statements-representations-period": "Datganiadau/Cyfnod Sylwadau",
"statements-representations-period-desc": "Gellir cyflwyno datganiadau a sylwadau ar gyfer yr apêl nawr.",
"order-submitted": "Gorchymyn Wedi'i Gyflwyno",
"order-submitted-desc": "Mae PEDW wedi derbyn y gorchymyn.",
"order-submission-registered": "Cyflwyniad Gorchymyn Wedi'i Gofrestru",
"order-submission-registered-desc": "Mae PEDW wedi cofrestru'r gorchymyn.",
"order-submission-validated": "Cyflwyniad Gorchymyn Wedi'i Ddilysu",
"order-submission-validated-desc": "Mae PEDW wedi canfod bod y gorchymyn yn ddilys.",
"case-started-case-in-progress": "Achos Wedi'i gychwyn/Achos ar y Gweill",
"case-started-case-in-progress-desc": "Mae'r gorchymyn wedi'i gychwyn.",
"statements": "Datganiadau",
"statements-desc": "Gellir cyflwyno datganiadau ar gyfer yr apêl nawr.",
"event-site-visit": "Digwyddiad/Ymweliad Safle",
"event-site-visit-desc": "Mae PEDW yn trefnu'r digwyddiad Gwrandawiad / Ymchwiliad ar gyfer y cais hwn, neu mae'r Arolygydd yn cynnal ei ymweliad â'r safle.",
"application-submitted": "Cais Wedi'i Gyflwyno",
"application-submitted-desc": "Mae PEDW wedi derbyn y cais.",
"application-start-case-in-progress": "Cais Wedi'i Ddechrau/Achos Ar Y Gweill",
"application-start-case-in-progress-desc": "Mae'r cais wedi'i gychwyn.",
"applicant-statement-on-representations": "Datganiad yr Ymgeisydd ar Gynrychioliadau",
"applicant-statement-on-representations-desc": "Gall yr ymgeisydd nawr gyflwyno ei ddatganiad ar gyfer y cais.",
"representatives-comment": "Sylwadau'r Cynrychiolwyr",
"representatives-comment-desc": "Gall cynrychiolwyr nawr gyflwyno eu sylwadau ar ddatganiad yr ymgeisydd.",
"applicants-final-comment": "Sylwadau Terfynol yr Ymgeisydd",
"applicants-final-comment-desc": "Gall yr ymgeisydd nawr gyflwyno sylwadau terfynol ar gyfer y cais.",
"order-registered": "Gorchymyn Wedi'i Gofrestru",
"order-validated": "Gorchymyn Wedi'i Ddilysu",
"report-to-desnz": "Adrodd i DESNZ",
"report-to-desnz-desc": "Mae'r Arolygydd wedi cyflwyno ei adroddiad i DESNZ.",
"case-in-progress-assessment": "Achos ar y Gweill / Asesiad?",
"decision-outcome": "Penderfyniad / Canlyniad",
"decision-outcome-desc": "Mae PEDW wedi gwneud ei benderfyniad ar ddilysrwydd y cais.",
"status-complete": "Wedi cwblhau",
"status-in-progress": "Ar y gweill",
"status-not-started": "Heb ddechrau",
"status-blocked": "Wedi'i rwystro"
}
+1 -1
View File
@@ -6,7 +6,7 @@
"summary-tab-map-label": " Map",
"summary-tab-events-label": " Digwyddiadau",
"summary-tab-documents-label": "Dogfennau",
"summary-tab-media-label": "Recordiadau digwyddiadau",
"summary-tab-media-label": "Recordiadau",
"summary-reference-label": "Cyfeirnod",
"summary-applicant-label": "Apelydd",
"summary-applicantonly-label": "Ymgeisydd",
+95
View File
@@ -0,0 +1,95 @@
{
"pre-application": "Pre-Application",
"pre-application-desc": "This project is at pre-application stage and it has not been submitted to PEDW for consideration. PEDW is not accepting representations at this stage. Any queries should be directed to the applicant.",
"environmental-impact-assessment-scoping": "Environmental Impact Assessment Scoping",
"environmental-impact-assessment-scoping-desc": "Determination of the scope of the future Environmental Statement. PEDW will only consider submissions about the proposed scope of the Environmental Statement at this time.",
"notification": "Notification",
"notification-desc": "PEDW has been notified by the applicant of their intention to submit an application. PEDW is not accepting representations at this stage.",
"acceptance-checking": "Acceptance Checking",
"acceptance-checking-desc": "The application has been submitted to PEDW and is currently being validated.",
"invalid-submission": "Invalid Submission",
"invalid-submission-desc": "The application submitted to PEDW has been found invalid and further information is required.",
"consultation": "Consultation",
"consultation-desc": "Consultation is open on this application. Representations may be submitted to PEDW during this period.",
"re-consultation": "Re-Consultation",
"re-consultation-desc": "PEDW is re-consulting on this application. Representations on limited matters will be accepted during the consultation period.",
"reporting": "Reporting",
"reporting-desc": "The Inspector is considering the evidence submitted for this application.",
"inspectors-decision": "Inspector(s) Decision",
"inspectors-decision-desc": "The Inspector has issued their decision on this application.",
"report-to-ministers": "Report to Ministers",
"report-to-ministers-desc": "The Inspector has submitted their report to the Welsh Ministers.",
"minister-s-decision": "Minister's Decision",
"minister-s-decision-desc": "The Welsh Ministers will issue their decision.",
"case-closed": "Case Closed",
"case-closed-desc": "PEDW has determined the application and the case has now been closed.",
"appeal-submitted": "Appeal Submitted",
"appeal-submitted-desc": "Appeal has been received by PEDW.",
"appeal-registered": "Appeal Registered",
"appeal-registered-desc": "Appeal has been registered by PEDW.",
"appeal-validated": "Appeal Validated",
"appeal-validated-desc": "PEDW has found the appeal valid.",
"case-in-progress": "Case in Progress",
"case-in-progress-desc": "The called-in application has been started.",
"questionnaire-lpa-to-notify": "Questionnaire / LPA to Notify",
"questionnaire-lpa-to-notify-desc": "The Local Planning Authority must submit their Questionnaire to PEDW and notify interested parties of the start of the appeal, and their opportunity to submit comments.",
"representations-period": "Representations Period",
"representations-period-desc": "Representations may now be submitted for the called-in application.",
"final-comments": "Final Comments",
"final-comments-desc": "Final comments may now be submitted for the order.",
"event": "Event?",
"event-desc": "PEDW is arranging the Hearing / Inquiry event for this called-in application.",
"site-visit": "Site Visit",
"site-visit-desc": "The Inspector is conducting their visit to the site.",
"decision-issued": "Decision Issued",
"decision-issued-desc": "The Inspector has submitted their decision for issuing.",
"application-called-in": "Application Called-In",
"application-called-in-desc": "Application has been called-in by the Welsh Ministers.",
"application-registered": "Application Registered",
"application-registered-desc": "Application has been registered by PEDW.",
"application-validated": "Application Validated",
"application-validated-desc": "PEDW has found the application valid.",
"lpa-to-notify": "LPA to Notify",
"lpa-to-notify-desc": "The Local Planning Authority must notify interested parties of the start of the called-in application, and their opportunity to submit comments.",
"report-issued-to-welsh-ministers": "Report Issued to Welsh Ministers",
"report-issued-to-welsh-ministers-desc": "The Inspector has submitted their recommendation report to the Welsh Ministers.",
"fee-due": "Fee Due",
"fee-due-desc": "If required, the payment of the fee is now due.",
"validated": "Validated",
"appeal-start-case-in-progress": "Appeal Start / Case in Progress",
"statements-representations-period": "Statements/Representations Period",
"statements-representations-period-desc": "Statements and representations may now be submitted for the appeal.",
"order-submitted": "Order Submitted",
"order-submitted-desc": "Order has been received by PEDW.",
"order-submission-registered": "Order Submission Registered",
"order-submission-registered-desc": "Order has been registered by PEDW.",
"order-submission-validated": "Order Submission Validated",
"order-submission-validated-desc": "PEDW has found the order valid.",
"case-started-case-in-progress": "Case started/Case in Progress",
"case-started-case-in-progress-desc": "The order has been started.",
"statements": "Statements",
"statements-desc": "Statements may now be submitted for the appeal.",
"event-site-visit": "Event/Site Visit",
"event-site-visit-desc": "PEDW is arranging the Hearing / Inquiry event for this application, or the Inspector is conducting their visit to the site.",
"application-submitted": "Application Submitted",
"application-submitted-desc": "Application has been received by PEDW.",
"application-start-case-in-progress": "Application Start/Case In Progress",
"application-start-case-in-progress-desc": "The application has been started.",
"applicant-statement-on-representations": "Applicant Statement on Representations",
"applicant-statement-on-representations-desc": "The applicant may now submit their statement for the application.",
"representatives-comment": "Representatives Comment",
"representatives-comment-desc": "Representatives may now submit their comments on the applicant's statement.",
"applicants-final-comment": "Applicants Final Comment",
"applicants-final-comment-desc": "The applicant may now submit final comments for the application.",
"order-registered": "Order Registered",
"order-validated": "Order Validated",
"report-to-desnz": "Report to DESNZ",
"report-to-desnz-desc": "The Inspector has submitted their report to DESNZ.",
"case-in-progress-assessment": "Case in Progress / Assessment?",
"decision-outcome": "Decision / Outcome",
"decision-outcome-desc": "PEDW has made their decision on the validity of the application.",
"status-complete": "Complete",
"status-in-progress": "In progress",
"status-not-started": "Not started",
"status-blocked": "Blocked"
}
@@ -86,7 +86,7 @@ export default async function ApiProxy(req, res) {
"&$count=true" +
"&$expand=" +
navigationProperty +
"($select=ticketnumber)" +
"($select=ticketnumber,statuscode)" +
(primaryIdAttribute == "pinswg_sipscase"
? ",pinswg_CaseDeadlineExtension_pinswg_sips($select=pinswg_casedeadlineextensionid,pinswg_noofdaysextended,pinswg_reasonforextension,pinswg_agreedorimposedextension,pinswg_newcasedeadline)"
: "");
@@ -86,7 +86,7 @@ export default async function ApiProxy(req, res) {
"&$count=true" +
"&$expand=" +
navigationProperty +
"($select=ticketnumber)" +
"($select=ticketnumber,statuscode)" +
(primaryIdAttribute == "pinswg_sipscase"
? ",pinswg_sipscase($select=ticketnumber),pinswg_CaseDeadlineExtension_pinswg_sips($select=pinswg_casedeadlineextensionid,pinswg_noofdaysextended,pinswg_reasonforextension,pinswg_agreedorimposedextension,pinswg_newcasedeadline),pinswg_sips_pinswg_sipsevent($select=pinswg_linktotheevent,pinswg_name,pinswg_dateeventrequested,pinswg_typeofevent,createdon,modifiedon)"
: "");
+1
View File
@@ -215,6 +215,7 @@ export const getServerSideProps = wrapper.getServerSideProps(
store.dispatch(setSearchDetails(searchDetailsObj));
store.dispatch(
setCurrentReference({
"statuscode": searchResultsObj.value[0].statuscode,
"ticketnumber": searchResultsObj.value[0].ticketnumber,
"currentReference": searchResultsObj.value[0].title,
"currentType": "searchResultsObj",
+1
View File
@@ -227,6 +227,7 @@ export const getServerSideProps = wrapper.getServerSideProps(
// store.dispatch(setSearchDetails(searchDetailsObj));
store.dispatch(
setCurrentReference({
"statuscode": searchResultsObj.value[0].statuscode,
"ticketnumber": searchResultsObj.value[0].ticketnumber,
"currentReference": searchResultsObj.value[0].title,
"currentType": "searchResultsObj",
+1
View File
@@ -387,6 +387,7 @@ export const getServerSideProps = wrapper.getServerSideProps(
store.dispatch(setSearchDetails(searchDetailsObj));
store.dispatch(
setCurrentReference({
"statuscode": searchResultsObj.value[0].statuscode,
"ticketnumber": searchResultsObj.value[0].ticketnumber,
"currentReference": searchResultsObj.value[0].title,
"currentType": "searchResultsObj",
+1
View File
@@ -222,6 +222,7 @@ export const getServerSideProps = wrapper.getServerSideProps(
// store.dispatch(setSearchDetails(searchDetailsObj));
store.dispatch(
setCurrentReference({
"statuscode": searchResultsObj.value[0].statuscode,
"ticketnumber": searchResultsObj.value[0].ticketnumber,
"currentReference": searchResultsObj.value[0].title,
"currentType": "searchResultsObj",
+6
View File
@@ -3283,3 +3283,9 @@ ul.subFieldList {
}
}
}
#case-status {
.govuk-task-list__name-and-hint {
width: 85%;
}
}