Merged PR 1114: added in guidance link and welsh trans

added in guidance link and welsh trans

Related work items: #10701
This commit is contained in:
Robert Bond
2024-04-02 16:46:03 +00:00
10 changed files with 110 additions and 55 deletions
+47 -44
View File
@@ -1774,51 +1774,54 @@ const renderField = ({ input, label, type, meta: { touched, error } }) => (
</div>
);
const renderSubFields = ({ fields }) => (
<ul>
<div>
{fields.map((member, index) => (
<div key={index}>
<h4>Tenant #{index + 1}</h4>
<div className="fieldArrayContainer">
<Field
id={`${member}.${fields.name}`}
name={`${member}.${fields.name}`}
type="text"
component={RenderTextfield}
label="Tenant Name"
className="govuk-input govuk-input--width-10"
/>
<Field
name={`${member}.dateserved`}
type="text"
component={RenderDatePicker}
label="Date served notice"
dateStart={"-6m"}
dateEnd={"0"}
className="govuk-input govuk-input--width-10"
/>
<button
type="button"
title="Remove tenant"
onClick={() => fields.remove(index)}
className="govuk-button fieldArrayDelete"
>
X
</button>
const renderSubFields = ({ fields }) => {
let { t } = useTranslation();
return (
<ul>
<div>
{fields.map((member, index) => (
<div key={index}>
<h4>Tenant #{index + 1}</h4>
<div className="fieldArrayContainer">
<Field
id={`${member}.${fields.name}`}
name={`${member}.${fields.name}`}
type="text"
component={RenderTextfield}
label="Tenant Name"
className="govuk-input govuk-input--width-10"
/>
<Field
name={`${member}.dateserved`}
type="text"
component={RenderDatePicker}
label="Date served notice"
dateStart={"-6m"}
dateEnd={"0"}
className="govuk-input govuk-input--width-10"
/>
<button
type="button"
title="Remove tenant"
onClick={() => fields.remove(index)}
className="govuk-button fieldArrayDelete"
>
X
</button>
</div>
</div>
</div>
))}
</div>
<button
type="button"
className="govuk-link fieldArrayLink"
onClick={() => fields.push({})}
>
Add Tenant
</button>
</ul>
);
))}
</div>
<button
type="button"
className="govuk-link fieldArrayLink"
onClick={() => fields.push({})}
>
{t("newappeal:new-appeal-add-tenant-label")}
</button>
</ul>
);
};
export const FieldArrayForm = (props) => {
const {
@@ -130,7 +130,7 @@ const AwaitingSubmissionFromBlob = (props) => {
)}
</div>
<div>
<b>LPA reference:</b>{" "}
<b>{t("myportal:lpa-reference-label")}:</b>{" "}
{
showTopThreeArr[key]
.pinswg_lpaapplicationreference
@@ -239,7 +239,13 @@ const AwaitingSubmissionFromBlob = (props) => {
"appealComplete"
) && (
<div className="cardModuleReference">
<b>Submission processing.....</b>
<b>
{" "}
{t(
"myportal:submission-processing-label"
)}
.....
</b>
</div>
)}
</div>
+1 -1
View File
@@ -28,7 +28,7 @@ export default function MakeNewAppeal() {
{t("myportal:makenewappeal-card-paragraph-three")}
</p>
<p className="govuk-body-s govuk govuk-!-margin-top-5">
<Link href="https://gov.wales">
<Link href={t("myportal:makenewappeal-card-guidance-link")}>
{t("myportal:makenewappeal-card-link-label")}
</Link>
</p>
+4
View File
@@ -2152,6 +2152,10 @@
"value": "Application form dated",
"value_cy": "Dyddiad y ffurflen gais"
},
{
"value": "Reason for Appeal",
"value_cy": "Rheswm dros yr Apêl"
},
{
"value": "Has your application been decided by the LPA?",
"value_cy": "A yw'r ACLl wedi penderfynu ar eich cais?"
+5 -2
View File
@@ -6,7 +6,8 @@
"makenewappeal-card-link": "berthnasol i'r math o apêl sydd gennych.",
"makenewappeal-card-paragraph-two": "Wedi i chi glicio'r botwm 'gwneud apêl newydd' isod, cewch eich arwain drwy broses i'ch helpu i ddewis y math cywir o apêl.",
"makenewappeal-card-paragraph-three": "Dim ond yn erbyn Gwrthod Caniatâd Cynllunio neu Fethiant i Benderfynu o fewn amser i'r Porth Gwaith Achos hwn y gallwch chi Gyflwyno apêl. Rhaid cyflwyno pob apêl arall trwy e-bost neu'r post.",
"makenewappeal-card-link-label": "Link label",
"makenewappeal-card-link-label": "Arweiniad",
"makenewappeal-card-guidance-link": "https://www.llyw.cymru/arweiniad-ar-apeliadau-cheisiadau",
"makenewappeal-card-button-label": "Gwneud apêl newydd",
"mycases-card-title": "Fy achosion",
"searchcases-card-title": "Chwilio apeliadau a Datblygiadau o Arwyddocâd Cenedlaethol",
@@ -36,9 +37,11 @@
"norecords-awaiting-submissions": "Nid oes gennych unrhyw gyflwyniadau sy'n aros",
"on-behalf-of-label": "Ar ran",
"appeal-type-label": "Math o apêl",
"lpa-reference-label": "Cyfeirnod yr LPA",
"raised-by-label": "Codwyd gan",
"representation-id": "Id cynrychiolaeth",
"representation-type": "Math o gynrychiolaeth",
"capacity": "Gallu",
"date-raised": "Dyddiad codi"
"date-raised": "Dyddiad codi",
"submission-processing-label": "Prosesu cyflwyniad"
}
+1
View File
@@ -62,6 +62,7 @@
"new-appeal-agricultural-holding-option-yes": "(a) Nid oes unrhyw ran or tir y maer apêl yn ymwneud ag ef yn ddaliad amaethyddol, neun rhan o ddaliad amaethyddol",
"new-appeal-agricultural-holding-option-no": "(b) (i) Mae safler apêl yn ddaliad amaethyddol, neun rhan o ddaliad amaethyddol, ar apelydd ywr unig denant amaethyddol",
"new-appeal-agricultural-holding-option-NA": "(b) (ii) Mae safler apêl yn ddaliad amaethyddol neun rhan o ddaliad amaethyddol ac maer apelydd (neur asiant) wedi rhoir hysbysiad gofynnol i bob person (ac eithrior apelydd) sydd, ar y diwrnod 21 diwrnod cyn y dyddiad or apêl, a oedd yn denant daliad amaethyddol ar y cyfan neu ran or tir y maer apêl yn ymwneud ag ef fel a restrir isod:",
"new-appeal-add-tenant-label": "Ychwanegu Tenant",
"new-appeal-procedure-option-virtual": "Rhith",
"new-appeal-procedure-option-inperson": "Yn bersonol",
"new-appeal-procedure-option-hybrid": "Hybrid",
+5 -2
View File
@@ -6,7 +6,8 @@
"makenewappeal-card-link": "relevant to your appeal type.",
"makenewappeal-card-paragraph-two": "Once you click the 'make a new appeal' button below you will be guided through a process to help you select the correct appeal type",
"makenewappeal-card-paragraph-three": "You can only Submit an appeal against a Refusal of planning Permission or Failure to determine within time vai this Casework Portal. All other appeals must be submitted via Email or post.",
"makenewappeal-card-link-label": "Link label",
"makenewappeal-card-link-label": "Guidance",
"makenewappeal-card-guidance-link": "https://www.gov.wales/planning-appeals-guidance",
"makenewappeal-card-button-label": "Make a new appeal",
"mycases-card-title": "My cases",
"searchcases-card-title": "Search appeals and Developments of National Significance",
@@ -36,9 +37,11 @@
"norecords-awaiting-submissions": "You have no awaiting submissions",
"on-behalf-of-label": "On behalf of",
"appeal-type-label": "Appeal type",
"lpa-reference-label": "LPA reference number",
"raised-by-label": "Raised by",
"representation-id": "Representation ID",
"representation-type": "Representation type",
"capacity": "Capacity",
"date-raised": "Date raised"
"date-raised": "Date raised",
"submission-processing-label": "Submission processing"
}
+1
View File
@@ -62,6 +62,7 @@
"new-appeal-agricultural-holding-option-yes": "(a) None of the land to which the appeal relates is, or is part of, an agricultural holding",
"new-appeal-agricultural-holding-option-no": "(b) (i) The appeal site is, or is part of an agricultural holding, and the appellant is the sole agricultural tenant",
"new-appeal-agricultural-holding-option-NA": "(b) (ii) The appeal site is, or is part of, an agricultural holding and the appellant (or the agent) has given the requisite notice to every person (other than the appellant) who, on the day 21 days before the date of the appeal, was a tenant of anagricultural holding on all or part of the land to which the appeal relates as listed below:",
"new-appeal-add-tenant-label": "Add Tenant",
"new-appeal-procedure-option-virtual": "Virtual",
"new-appeal-procedure-option-inperson": "In person",
"new-appeal-procedure-option-hybrid": "Hybrid",
+38 -3
View File
@@ -165,13 +165,48 @@ const authOptions = (locale, req, res) => {
);
let newURL =
locale == "cy"
? process.env.CY_API_ROOT
? process.env.CY_API_ROOT +
"/api/auth/callback/email?callbackUrl=" +
encodeURIComponent(process.env.CY_API_ROOT) +
"&token=" +
searchParams.get("token") +
"&email=" +
encodeURIComponent(email)
: process.env.NEXTAUTH_URL;
//console.log(newURL, searchParams.get("token"));
// console.log(
// "============================================================\n",
// locale + "\n",
// "============================================================\n",
// newURL + "\n",
// encodeURIComponent(newURL) + "\n",
// "============================================================\n",
// url + "\n",
// "============================================================\n",
// newURL + "\n",
// "============================================================\n",
// searchParams.get("token") + "\n",
// "============================================================\n"
// );
console.log(
"============================================================\n",
locale == "cy"
? url.split("/api")[0] +
"/cy/api" +
url.split("/api")[1]
: url,
"============================================================\n"
);
const personalisation = {
"emailAddress": email,
"signInLink": url,
"signInLink":
locale == "cy"
? url.split("&token")[0] +
"/cy&token" +
url.split("&token")[1]
: url,
"linkExpiry": 2 * 60 * 60,
};
-1
View File
@@ -7,7 +7,6 @@ import Header from "../../components/header";
import Breadcrumbs from "../../components/breadcrumbs";
import { getCsrfToken } from "next-auth/react";
import { parseCookies, setCookie, destroyCookie } from "nookies";
import { ca } from "date-fns/locale";
const SignIn = (props) => {
let { t, lang } = useTranslation();