From 1763af155e15513127ea2982d37fdf4441d6b9fb Mon Sep 17 00:00:00 2001 From: Ed Chalstrey Date: Mon, 23 May 2022 11:34:15 +0100 Subject: [PATCH] fake_slug hack --- app/src/frontend/building/data-container.tsx | 2 +- app/src/frontend/config/data-fields-config.ts | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/app/src/frontend/building/data-container.tsx b/app/src/frontend/building/data-container.tsx index 911e9567..203890dd 100644 --- a/app/src/frontend/building/data-container.tsx +++ b/app/src/frontend/building/data-container.tsx @@ -248,7 +248,7 @@ const withCopyEdit: (wc: React.ComponentType) => DataContaine } const edits = (slug == 'current_landuse_group') ? - {['date_year']: value} : + {['fake_slug']: value} : {[slug]: value} this.doSubmit(edits); diff --git a/app/src/frontend/config/data-fields-config.ts b/app/src/frontend/config/data-fields-config.ts index f808f000..ef01e74d 100644 --- a/app/src/frontend/config/data-fields-config.ts +++ b/app/src/frontend/config/data-fields-config.ts @@ -632,7 +632,8 @@ export const dataFields = { /* eslint-disable @typescript-eslint/camelcase */ year_demolished: { min: 1993, max: 1994 }, lifespan: "2-5", overlap_present: "50%", links: ["", ""]} ] - } + }, + fake_slug: {} }; export const allFieldsConfig = {...dataFields, ...buildingUserFields}; \ No newline at end of file