added tenant fieldarray and date ranges
This commit is contained in:
@@ -42,6 +42,9 @@ export default function BuildField(props) {
|
||||
case "{4273EDBD-AC1D-40d3-9FB2-095C621B552D}":
|
||||
return <>{fieldValue}</>;
|
||||
break;
|
||||
case "{0273EDBD-AC1D-40d3-9FB2-095C621B552D}":
|
||||
return <>{}</>;
|
||||
break;
|
||||
case "{5B773807-9FB2-42db-97C3-7A91EFF8ADFF}":
|
||||
return (
|
||||
<>
|
||||
|
||||
@@ -10,6 +10,7 @@ import {
|
||||
getFormCollectionByID,
|
||||
getPickListLabel,
|
||||
getRadioLabel,
|
||||
getFieldArrayLabel,
|
||||
} from "../../components/utils";
|
||||
|
||||
import {
|
||||
@@ -169,6 +170,35 @@ let BuildCheckRow = (props) => {
|
||||
: fieldtype[0].value ==
|
||||
"{16D63FD6-119B-4353-BDCA-18358721C3FE}"
|
||||
? "ssss"
|
||||
: fieldtype[0].value ==
|
||||
"{0273EDBD-AC1D-40d3-9FB2-095C621B552D}"
|
||||
? props.props.form[
|
||||
"appealForm"
|
||||
].values[
|
||||
datafieldname[0].value
|
||||
].map((tenant, index) => {
|
||||
return (
|
||||
<div
|
||||
key={index}
|
||||
style={{
|
||||
display:
|
||||
"flex",
|
||||
}}
|
||||
>
|
||||
<div className="govuk-!-width-one-half">
|
||||
{
|
||||
tenant.pinswg_agriculturaltenantname
|
||||
}
|
||||
</div>
|
||||
<div className="govuk-!-width-one-half">
|
||||
Served:{" "}
|
||||
{formatDate(
|
||||
tenant.dateserved
|
||||
)}
|
||||
</div>
|
||||
</div>
|
||||
);
|
||||
})
|
||||
: props.props.form["appealForm"]
|
||||
.values[
|
||||
datafieldname[0].value
|
||||
|
||||
@@ -72,7 +72,7 @@ let BuildCheckSection = (props) => {
|
||||
};
|
||||
|
||||
let buildAppealFilesArray = [];
|
||||
console.log("attached docs: - ", buildAppealFilesArray);
|
||||
//console.log("attached docs: - ", buildAppealFilesArray);
|
||||
|
||||
let filesUplaodObj = Object.keys(props.props.form.appealForm.values)
|
||||
.filter(function (k) {
|
||||
@@ -83,8 +83,6 @@ let BuildCheckSection = (props) => {
|
||||
return newData;
|
||||
}, {});
|
||||
|
||||
console.log(filesUplaodObj);
|
||||
|
||||
for (let key in filesUplaodObj) {
|
||||
for (let j in filesUplaodObj[key]) {
|
||||
typeof filesUplaodObj[key][j].name != "undefined" &&
|
||||
@@ -95,8 +93,6 @@ let BuildCheckSection = (props) => {
|
||||
}
|
||||
}
|
||||
|
||||
console.log(buildAppealFilesArray);
|
||||
|
||||
let pdfObj = props.props.form.appealForm.values;
|
||||
|
||||
Object.assign(pdfObj, {
|
||||
|
||||
@@ -13,6 +13,7 @@ import {
|
||||
RichMultiLinefield,
|
||||
Textfield,
|
||||
YesNofield,
|
||||
FieldArrayForm,
|
||||
} from "../elements";
|
||||
|
||||
export default function BuildField(props) {
|
||||
@@ -217,6 +218,17 @@ export default function BuildField(props) {
|
||||
);
|
||||
break;
|
||||
|
||||
case "{0273EDBD-AC1D-40d3-9FB2-095C621B552D}":
|
||||
return (
|
||||
<FieldArrayForm
|
||||
name={props.datafieldname}
|
||||
label={props.label}
|
||||
form={props.props.props.form}
|
||||
formProps={props.props.props.props.form}
|
||||
parentField={props.parentField}
|
||||
parentFieldShowOnValue={props.parentFieldShowOnValue}
|
||||
/>
|
||||
);
|
||||
case "{9EF39988-22BB-4f0b-BBBE-64B5A3748AEE}":
|
||||
return (
|
||||
<CheckBoxfield
|
||||
|
||||
Reference in New Issue
Block a user