From 0232d00842fd8574dc3a441173385c1495c0eecd Mon Sep 17 00:00:00 2001 From: Ramesh Mane <101566080+rameshmane7218@users.noreply.github.com> Date: Sat, 7 Dec 2024 16:25:56 +0530 Subject: [PATCH] fix(nc-gui): remove audit logs from team and settings page --- .../nc-gui/components/workspace/AuditLogs.vue | 729 +----------------- packages/nc-gui/pages/account/index.vue | 14 - .../nc-gui/pages/account/index/[page].vue | 1 - packages/nc-gui/store/workspace.ts | 33 +- 4 files changed, 6 insertions(+), 771 deletions(-) diff --git a/packages/nc-gui/components/workspace/AuditLogs.vue b/packages/nc-gui/components/workspace/AuditLogs.vue index 2a1ac62741..829e4eaeac 100644 --- a/packages/nc-gui/components/workspace/AuditLogs.vue +++ b/packages/nc-gui/components/workspace/AuditLogs.vue @@ -1,8 +1,4 @@ - + diff --git a/packages/nc-gui/pages/account/index.vue b/packages/nc-gui/pages/account/index.vue index 1c3b1e289d..6b4d9c61bb 100644 --- a/packages/nc-gui/pages/account/index.vue +++ b/packages/nc-gui/pages/account/index.vue @@ -128,20 +128,6 @@ const isPending = computed(() => !emailConfigured.value || !storageConfigured.va
{{ $t('title.tokens') }}
- -
- - -
{{ $t('title.auditLogs') }}
-
-
- diff --git a/packages/nc-gui/store/workspace.ts b/packages/nc-gui/store/workspace.ts index 333d2655f4..2eb18f3ea6 100644 --- a/packages/nc-gui/store/workspace.ts +++ b/packages/nc-gui/store/workspace.ts @@ -261,36 +261,9 @@ export const useWorkspace = defineStore('workspaceStore', () => { const loadAudits = async ( _workspaceId?: string, - page: number = auditPaginationData.value.page!, - limit: number = auditPaginationData.value.pageSize!, - ) => { - try { - if (limit * (page - 1) > auditPaginationData.value.totalRows!) { - auditPaginationData.value.page = 1 - page = 1 - } - - const { list, pageInfo } = isUIAllowed('workspaceAuditList') - ? await $api.utils.projectAuditList({ - offset: limit * (page - 1), - limit, - ...auditLogsQuery.value, - }) - : await $api.base.auditList(auditLogsQuery.value.baseId, { - offset: limit * (page - 1), - limit, - ...auditLogsQuery.value, - }) - - audits.value = list - auditPaginationData.value.totalRows = pageInfo.totalRows ?? 0 - } catch (e) { - message.error(await extractSdkResponseErrorMsg(e)) - audits.value = [] - auditPaginationData.value.totalRows = 0 - auditPaginationData.value.page = 1 - } - } + _page: number = auditPaginationData.value.page!, + _limit: number = auditPaginationData.value.pageSize!, + ) => {} function setLoadingState(isLoading = false) { isWorkspaceLoading.value = isLoading