From 12973aaf981466afdfa75da541c0b2ab86af87eb Mon Sep 17 00:00:00 2001 From: Wing-Kam Wong Date: Sat, 25 Feb 2023 12:50:22 +0800 Subject: [PATCH] feat(nc-gui): use decimal input for 'pastNumberOfDays', 'nextNumberOfDays' --- .../nc-gui/components/smartsheet/toolbar/FilterInput.vue | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/packages/nc-gui/components/smartsheet/toolbar/FilterInput.vue b/packages/nc-gui/components/smartsheet/toolbar/FilterInput.vue index 5c18353e49..6a2072cba4 100644 --- a/packages/nc-gui/components/smartsheet/toolbar/FilterInput.vue +++ b/packages/nc-gui/components/smartsheet/toolbar/FilterInput.vue @@ -117,9 +117,11 @@ const componentMap: Partial> = $computed(() => { // use MultiSelect for SingleSelect columns for anyof / nanyof filters isSingleSelect: ['anyof', 'nanyof'].includes(props.filter.comparison_op!) ? MultiSelect : SingleSelect, isMultiSelect: MultiSelect, - isDate: ['daysAgo', 'daysFromNow'].includes(props.filter.comparison_sub_op!) ? Decimal : DatePicker, + isDate: ['daysAgo', 'daysFromNow', 'pastNumberOfDays', 'nextNumberOfDays'].includes(props.filter.comparison_sub_op!) + ? Decimal + : DatePicker, isYear: YearPicker, - isDateTime: ['daysAgo', 'daysFromNow'].includes(props.filter.comparison_sub_op!) + isDateTime: ['daysAgo', 'daysFromNow', 'pastNumberOfDays', 'nextNumberOfDays'].includes(props.filter.comparison_sub_op!) ? Decimal : DateTimePicker, isTime: TimePicker,