diff --git a/app/src/api/config/dataFields.ts b/app/src/api/config/dataFields.ts index e77c8358..0cf01a03 100644 --- a/app/src/api/config/dataFields.ts +++ b/app/src/api/config/dataFields.ts @@ -285,6 +285,14 @@ export const buildingAttributesConfig = valueType()({ /* eslint edit: true, verify: true, }, + planning_crowdsourced_site_completion_source_type: { + edit: true, + verify: true, + }, + planning_crowdsourced_site_completion_source_links: { + edit: true, + verify: true, + }, planning_crowdsourced_planning_id: { edit: true, verify: true, @@ -333,6 +341,14 @@ export const buildingAttributesConfig = valueType()({ /* eslint edit: true, verify: true, }, + planning_missing_data: { + edit: true, + verify: true, + }, + planning_missing_data_links: { + edit: true, + verify: true, + }, sust_breeam_rating: { edit: true, verify: true, diff --git a/app/src/frontend/building/data-containers/planning.tsx b/app/src/frontend/building/data-containers/planning.tsx index d2d3588e..ce091231 100644 --- a/app/src/frontend/building/data-containers/planning.tsx +++ b/app/src/frontend/building/data-containers/planning.tsx @@ -65,6 +65,8 @@ const PlanningView: React.FunctionComponent = (props) => { } const { flood, floodSwitchOnClick, housing, housingSwitchOnClick, creative, creativeSwitchOnClick, vista, vistaSwitchOnClick, parcel, parcelSwitchOnClick, conservation, conservationSwitchOnClick, darkLightTheme } = useDisplayPreferences(); const communityLinkUrl = `/${props.mode}/${Category.Community}/${props.building.building_id}`; + const currentYear = new Date().getFullYear(); + return ( @@ -88,36 +90,111 @@ const PlanningView: React.FunctionComponent = (props) => { } - - + {props.building.planning_crowdsourced_site_completion_status == null ? <> : + <> + + + + {(props.building.planning_crowdsourced_site_completion_source_type == dataFields.planning_crowdsourced_site_completion_source_type.items[0] || + props.building.planning_crowdsourced_site_completion_source_type == dataFields.planning_crowdsourced_site_completion_source_type.items[1] || + props.building.planning_crowdsourced_site_completion_source_type == null) ? <> : + <> + + + } + + } - - + {props.building.planning_missing_data == null ? <> : + <> + + + } If you feel there are incorrect or missing data relating to this building please contact: planningdata@London.gov.uk @@ -179,41 +256,41 @@ const PlanningView: React.FunctionComponent = (props) => {