diff --git a/packages/nc-gui/components/smartsheet/grid/Table.vue b/packages/nc-gui/components/smartsheet/grid/Table.vue index e12620dd12..77898830c4 100644 --- a/packages/nc-gui/components/smartsheet/grid/Table.vue +++ b/packages/nc-gui/components/smartsheet/grid/Table.vue @@ -181,7 +181,7 @@ const gridRect = useElementBounding(gridWrapper) // #Permissions const { isUIAllowed } = useRoles() -const hasEditPermission = computed(() => isUIAllowed('dataEdit')) +const hasEditPermission = computed(() => isUIAllowed('dataEdit') && !isLocked.value) const isAddingColumnAllowed = computed(() => !readOnly.value && !isLocked.value && isUIAllowed('fieldAdd') && !isSqlView.value) const { onDrag, onDragStart, draggedCol, dragColPlaceholderDomRef, toBeDroppedColId } = useColumnDrag({ @@ -223,9 +223,7 @@ const _contextMenu = ref(false) const contextMenu = computed({ get: () => _contextMenu.value, set: (val) => { - if (hasEditPermission.value) { - _contextMenu.value = val - } + _contextMenu.value = val }, }) const contextMenuClosing = ref(false) @@ -1549,14 +1547,12 @@ onKeyStroke('ArrowDown', onDown) +