Browse Source

fix: injection warnings on shared view

Signed-off-by: mertmit <mertmit99@gmail.com>
pull/4876/head
mertmit 2 years ago
parent
commit
9f3e55a736
  1. 3
      packages/nc-gui/components/shared-view/Grid.vue
  2. 4
      packages/nc-gui/components/smartsheet/toolbar/FieldsMenu.vue

3
packages/nc-gui/components/shared-view/Grid.vue

@ -23,7 +23,7 @@ const { signedIn } = useGlobal()
const { loadProject } = useProject()
useProvideSmartsheetStore(sharedView, meta, true, sorts, nestedFilters)
const { isLocked } = useProvideSmartsheetStore(sharedView, meta, true, sorts, nestedFilters)
const reloadEventHook = createEventHook()
@ -33,6 +33,7 @@ provide(MetaInj, meta)
provide(ActiveViewInj, sharedView)
provide(FieldsInj, ref(meta.value?.columns || []))
provide(IsPublicInj, ref(true))
provide(IsLockedInj, isLocked)
if (signedIn.value) {
try {

4
packages/nc-gui/components/smartsheet/toolbar/FieldsMenu.vue

@ -27,7 +27,7 @@ const activeView = inject(ActiveViewInj, ref())
const reloadDataHook = inject(ReloadViewDataHookInj)!
const reloadViewMetaHook = inject(ReloadViewMetaHookInj)!
const reloadViewMetaHook = inject(ReloadViewMetaHookInj, undefined)!
const rootFields = inject(FieldsInj)
@ -108,7 +108,7 @@ const coverImageColumnId = computed({
})
;(activeView.value.view as KanbanType).fk_cover_image_col_id = val
}
reloadViewMetaHook.trigger()
reloadViewMetaHook?.trigger()
}
},
})

Loading…
Cancel
Save