From 8e572f285fa83afc4b6b18ed425214067bad9c13 Mon Sep 17 00:00:00 2001 From: Andreas Hasenkopf Date: Fri, 8 Dec 2023 13:29:30 +0100 Subject: [PATCH] Fixed missing input field for filters closes #175 --- frontend/src/components/SearchPanel.vue | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/frontend/src/components/SearchPanel.vue b/frontend/src/components/SearchPanel.vue index 4f6ce66..0687462 100644 --- a/frontend/src/components/SearchPanel.vue +++ b/frontend/src/components/SearchPanel.vue @@ -133,6 +133,12 @@ export default { t[a.name] = a.type; } return t; + }, + typeInputMap() { + const dict = {...TYPE_INPUT_MAP}; + // Override the default text area with a one-line input field + dict.STR = "TextInput"; + return dict } }, methods: { @@ -159,7 +165,7 @@ export default { } try { const fieldType = this.fieldTypes[row.field].toUpperCase(); - return TYPE_INPUT_MAP[fieldType]; + return this.typeInputMap[fieldType]; } catch (e) { console.error(e); return null; @@ -189,8 +195,7 @@ export default { filters: [], searchQuery: "", allValues: false, - listMode: 'active', - TYPE_INPUT_MAP, + listMode: 'active' }; }, };