From d5a70645a18fcb95562d7b4b9fc85bfe5387728a Mon Sep 17 00:00:00 2001 From: Wing-Kam Wong Date: Wed, 10 Aug 2022 17:15:01 +0800 Subject: [PATCH] fix(gui-v2): lint in form view --- .../nc-gui-v2/components/smartsheet/Form.vue | 19 ++----------------- 1 file changed, 2 insertions(+), 17 deletions(-) diff --git a/packages/nc-gui-v2/components/smartsheet/Form.vue b/packages/nc-gui-v2/components/smartsheet/Form.vue index 79bb940d67..4a50005746 100644 --- a/packages/nc-gui-v2/components/smartsheet/Form.vue +++ b/packages/nc-gui-v2/components/smartsheet/Form.vue @@ -4,7 +4,7 @@ import { RelationTypes, UITypes, getSystemColumns, isVirtualCol } from 'nocodb-s import { notification } from 'ant-design-vue' import type { Permission } from '~/composables/useUIPermission/rolePermissions' import { computed, inject, onClickOutside, useDebounceFn } from '#imports' -import { ActiveViewInj, FieldsInj, IsFormInj, MetaInj } from '~/context' +import { ActiveViewInj, IsFormInj, MetaInj } from '~/context' import { extractSdkResponseErrorMsg } from '~/utils' import MdiPlusIcon from '~icons/mdi/plus' import MdiDragIcon from '~icons/mdi/drag-vertical' @@ -35,18 +35,7 @@ const view = inject(ActiveViewInj) if (meta) useProvideColumnCreateStore(meta) -const { - loadData, - paginationData, - formattedData: data, - loadFormView, - insertRow, - formColumnData, - formViewData, - changePage, - updateRowProperty, - updateFormView, -} = useViewData(meta, view as any) +const { loadFormView, insertRow, formColumnData, formViewData, updateFormView } = useViewData(meta, view as any) const { showAll, hideAll, saveOrUpdate } = useViewColumns(view, meta as any, false, async () => { await loadFormView() @@ -59,8 +48,6 @@ const localColumns = ref>([]) const hiddenColumns = ref>([]) -const availableColumns = inject(FieldsInj, ref([])) - const draggableRef = ref() const editOrAddRef = ref() @@ -79,8 +66,6 @@ const submitted = ref(false) const activeRow = ref('') -const formView = ref({}) - function updateView() { if ((formViewData.value?.subheading?.length || 0) > 255) { notification.error({