updated translations for lpas
This commit is contained in:
@@ -7,6 +7,7 @@ import BuildRow from "./buildrow";
|
||||
import { reduxForm, formValueSelector, Field } from "redux-form";
|
||||
import { useDispatch, useSelector, shallowEqual, connect } from "react-redux";
|
||||
import jsonpath from "jsonpath";
|
||||
import transLookup from "../../data/lookuptranslations.json";
|
||||
|
||||
import data from "../../data/collections.json";
|
||||
import {
|
||||
@@ -90,7 +91,7 @@ let CreateCase = (props) => {
|
||||
//onChange={(e) => props.onChangeSelectLPA(e)}
|
||||
>
|
||||
<option value="" disabled defaultValue>
|
||||
Select...
|
||||
{t("common:drop-down-select")}
|
||||
</option>
|
||||
{_.isEmpty(optionsObj)
|
||||
? ""
|
||||
@@ -100,7 +101,15 @@ let CreateCase = (props) => {
|
||||
key={key}
|
||||
value={optionsObj[key].accountid}
|
||||
>
|
||||
{optionsObj[key].name}
|
||||
{router.locale == "cy"
|
||||
? jsonpath.query(
|
||||
transLookup,
|
||||
'$..[?(@.value=="' +
|
||||
optionsObj[key]
|
||||
.name +
|
||||
'")].value_cy'
|
||||
)
|
||||
: optionsObj[key].name}
|
||||
</option>
|
||||
);
|
||||
})}
|
||||
@@ -151,7 +160,7 @@ let CreateCase = (props) => {
|
||||
//onChange={(e) => props.onChangeSelectAppealType(e)}
|
||||
>
|
||||
<option value="" disabled defaultValue>
|
||||
Select...
|
||||
{t("common:drop-down-select")}
|
||||
</option>
|
||||
{_.isEmpty(optionsObj)
|
||||
? ""
|
||||
@@ -190,6 +199,14 @@ let CreateCase = (props) => {
|
||||
optionsObj[key].value
|
||||
)
|
||||
? ""
|
||||
: router.locale == "cy"
|
||||
? jsonpath.query(
|
||||
transLookup,
|
||||
'$..[?(@.value=="' +
|
||||
optionsObj[key]
|
||||
.value +
|
||||
'")].value_cy'
|
||||
)
|
||||
: optionsObj[key].value}
|
||||
</option>
|
||||
);
|
||||
@@ -248,8 +265,8 @@ let CreateCase = (props) => {
|
||||
component={RenderLPAList}
|
||||
optionsObj={lpaOptionsObj}
|
||||
validate={[required]}
|
||||
label="Select your local planning authority"
|
||||
errorMsg="Local authority is required"
|
||||
label={t("newappeal:select-lpa-label")}
|
||||
errorMsg={t("newappeal:select-lpa-label-error-msg")}
|
||||
/>
|
||||
|
||||
<Field
|
||||
@@ -257,8 +274,8 @@ let CreateCase = (props) => {
|
||||
component={RenderAppealTypeList}
|
||||
optionsObj={appealOptionsObj}
|
||||
validate={[required]}
|
||||
label="Select an appeal type"
|
||||
errorMsg="Appeal type is required"
|
||||
label={t("newappeal:select-appeal-type-label")}
|
||||
errorMsg={t("newappeal:select-appeal-type-label-error-msg")}
|
||||
/>
|
||||
|
||||
<button
|
||||
@@ -266,7 +283,7 @@ let CreateCase = (props) => {
|
||||
className="govuk-button"
|
||||
data-module="govuk-button"
|
||||
>
|
||||
Continue
|
||||
{t("common:continue-button")}
|
||||
</button>
|
||||
</form>
|
||||
);
|
||||
|
||||
Reference in New Issue
Block a user