From 94d6e2b75e7ef59e763bc445c3dc3e37f2fc8f4b Mon Sep 17 00:00:00 2001 From: Wing-Kam Wong Date: Sat, 11 Feb 2023 14:06:06 +0800 Subject: [PATCH] fix(nc-gui): use MultiSelect only for anyof / nanyof filters --- packages/nc-gui/components/smartsheet/toolbar/FilterInput.vue | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/packages/nc-gui/components/smartsheet/toolbar/FilterInput.vue b/packages/nc-gui/components/smartsheet/toolbar/FilterInput.vue index 32c030d613..2c06ec73b6 100644 --- a/packages/nc-gui/components/smartsheet/toolbar/FilterInput.vue +++ b/packages/nc-gui/components/smartsheet/toolbar/FilterInput.vue @@ -26,6 +26,7 @@ import { useProject, } from '#imports' import type { Filter } from '~/lib' +import SingleSelect from '~/components/cell/SingleSelect.vue' import MultiSelect from '~/components/cell/MultiSelect.vue' import DatePicker from '~/components/cell/DatePicker.vue' import YearPicker from '~/components/cell/YearPicker.vue' @@ -113,7 +114,7 @@ const booleanOptions = [ const componentMap: Partial> = { // use MultiSelect for SingleSelect columns for anyof / nanyof filters - isSingleSelect: MultiSelect, + isSingleSelect: ['anyof', 'nanyof'].includes(props.filter.comparison_op) ? MultiSelect : SingleSelect, isMultiSelect: MultiSelect, isDate: DatePicker, isYear: YearPicker,