From 92d4da71523abcb96ea9ace1b2c4974f23b9a7c5 Mon Sep 17 00:00:00 2001 From: Pranav C Date: Wed, 31 Aug 2022 14:53:43 +0530 Subject: [PATCH] fix(gui-v2): block expand form in hared grid child list(hm/mm) modal Signed-off-by: Pranav C --- packages/nc-gui-v2/components/smartsheet/Gallery.vue | 4 ++-- .../components/virtual-cell/components/ListChildItems.vue | 1 + packages/nc-gui-v2/composables/useLTARStore.ts | 8 +++++--- 3 files changed, 8 insertions(+), 5 deletions(-) diff --git a/packages/nc-gui-v2/components/smartsheet/Gallery.vue b/packages/nc-gui-v2/components/smartsheet/Gallery.vue index 2f56d14cb4..ca9c54955c 100644 --- a/packages/nc-gui-v2/components/smartsheet/Gallery.vue +++ b/packages/nc-gui-v2/components/smartsheet/Gallery.vue @@ -203,10 +203,10 @@ openNewRecordFormHook?.on(async () => { display: block; font-size: 0; height: 3px; - opacity: .3; + opacity: 0.3; outline: none; padding: 0; - transition: all .5s; + transition: all 0.5s; width: 100%; } .ant-carousel.gallery-carousel :deep(.slick-dots li.slick-active div > div) { diff --git a/packages/nc-gui-v2/components/virtual-cell/components/ListChildItems.vue b/packages/nc-gui-v2/components/virtual-cell/components/ListChildItems.vue index 70e32a2b48..8339270602 100644 --- a/packages/nc-gui-v2/components/virtual-cell/components/ListChildItems.vue +++ b/packages/nc-gui-v2/components/virtual-cell/components/ListChildItems.vue @@ -101,6 +101,7 @@ const expandedFormRow = ref() class="!my-4 hover:(!bg-gray-200/50 shadow-md)" @click=" () => { + if (readonly) return expandedFormRow = row expandedFormDlg = true } diff --git a/packages/nc-gui-v2/composables/useLTARStore.ts b/packages/nc-gui-v2/composables/useLTARStore.ts index fe3791f736..60adb6e0b5 100644 --- a/packages/nc-gui-v2/composables/useLTARStore.ts +++ b/packages/nc-gui-v2/composables/useLTARStore.ts @@ -159,10 +159,11 @@ const [useProvideLTARStore, useLTARStore] = useInjectionState( { limit: String(childrenListPagination.size), offset: String(childrenListPagination.size * (childrenListPagination.page - 1)), - where: childrenListPagination.query && `(${relatedTablePrimaryValueProp.value},like,${childrenListPagination.query})`, + where: + childrenListPagination.query && `(${relatedTablePrimaryValueProp.value},like,${childrenListPagination.query})`, } as any, ) - }else{ + } else { childrenList.value = await $api.dbTableRow.nestedList( NOCO, (project?.value?.id || sharedView?.value?.view?.project_id) as string, @@ -173,7 +174,8 @@ const [useProvideLTARStore, useLTARStore] = useInjectionState( { limit: String(childrenListPagination.size), offset: String(childrenListPagination.size * (childrenListPagination.page - 1)), - where: childrenListPagination.query && `(${relatedTablePrimaryValueProp.value},like,${childrenListPagination.query})`, + where: + childrenListPagination.query && `(${relatedTablePrimaryValueProp.value},like,${childrenListPagination.query})`, } as any, ) }