From 605ecfc532044ee637f45cb20710b4b50550b921 Mon Sep 17 00:00:00 2001 From: Wing-Kam Wong Date: Sat, 11 Feb 2023 12:09:16 +0800 Subject: [PATCH] fix(nc-gui): disable system fields in filter --- .../smartsheet/toolbar/FieldListAutoCompleteDropdown.vue | 2 +- packages/nc-gui/composables/useViewFilters.ts | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/packages/nc-gui/components/smartsheet/toolbar/FieldListAutoCompleteDropdown.vue b/packages/nc-gui/components/smartsheet/toolbar/FieldListAutoCompleteDropdown.vue index 68df38797f..17211b05aa 100644 --- a/packages/nc-gui/components/smartsheet/toolbar/FieldListAutoCompleteDropdown.vue +++ b/packages/nc-gui/components/smartsheet/toolbar/FieldListAutoCompleteDropdown.vue @@ -21,7 +21,7 @@ const localValue = computed({ const options = computed(() => meta.value?.columns ?.filter((c: ColumnType) => { - if (c.uidt === UITypes.QrCode || c.uidt === UITypes.Barcode || c.uidt === UITypes.ID) { + if (c.uidt === UITypes.QrCode || c.uidt === UITypes.Barcode || c.uidt === UITypes.ID || c.system) { return false } else if (isSort) { /** ignore hasmany and manytomany relations if it's using within sort menu */ diff --git a/packages/nc-gui/composables/useViewFilters.ts b/packages/nc-gui/composables/useViewFilters.ts index 365ca54329..04b99dc032 100644 --- a/packages/nc-gui/composables/useViewFilters.ts +++ b/packages/nc-gui/composables/useViewFilters.ts @@ -75,7 +75,7 @@ export function useViewFilters( const options = computed(() => meta.value?.columns?.filter((c: ColumnType) => { - if (c.uidt === UITypes.QrCode || c.uidt === UITypes.Barcode || c.uidt === UITypes.ID) { + if (c.uidt === UITypes.QrCode || c.uidt === UITypes.Barcode || c.uidt === UITypes.ID || c.system) { return false } else { const isVirtualSystemField = c.colOptions && c.system