From ff027cb64b00064b8f8515accb8fad02ce19d878 Mon Sep 17 00:00:00 2001 From: Maciej Ziarkowski Date: Thu, 19 Mar 2020 14:41:44 +0000 Subject: [PATCH] Remove current land use class from frontend --- app/src/api/services/building.ts | 2 +- .../frontend/building/data-containers/use.tsx | 16 ++++------------ app/src/frontend/data_fields.ts | 8 ++------ 3 files changed, 7 insertions(+), 19 deletions(-) diff --git a/app/src/api/services/building.ts b/app/src/api/services/building.ts index 79511324..197b57d1 100644 --- a/app/src/api/services/building.ts +++ b/app/src/api/services/building.ts @@ -405,7 +405,7 @@ const BUILDING_FIELD_WHITELIST = new Set([ 'building_attachment_form', 'date_change_building_use', - 'current_landuse_class', + // 'current_landuse_class', 'current_landuse_group', 'current_landuse_order' ]); diff --git a/app/src/frontend/building/data-containers/use.tsx b/app/src/frontend/building/data-containers/use.tsx index 7956f9ab..26aa3b8f 100644 --- a/app/src/frontend/building/data-containers/use.tsx +++ b/app/src/frontend/building/data-containers/use.tsx @@ -13,23 +13,11 @@ import { CategoryViewProps } from './category-view-props'; */ const UseView: React.FunctionComponent = (props) => ( - = (props) => ( copy={props.copy} onChange={props.onChange} /> + { + props.mode != 'view' && + + } ); const UseContainer = withCopyEdit(UseView); diff --git a/app/src/frontend/data_fields.ts b/app/src/frontend/data_fields.ts index 7e46cdad..fb88db43 100644 --- a/app/src/frontend/data_fields.ts +++ b/app/src/frontend/data_fields.ts @@ -153,17 +153,13 @@ export const dataFields = { title: "Longitude", }, - current_landuse_class: { - category: Category.LandUse, - title: "Current Land Use Class" - }, current_landuse_group: { category: Category.LandUse, - title: "Current Land Use Group" + title: "Current Land Use (Group)" }, current_landuse_order: { category: Category.LandUse, - title: "Current Land Use Order" + title: "Current Land Use (Order)" }, building_attachment_form: {