From 913ce9928ebc8887aeb7af982563df4823ddd390 Mon Sep 17 00:00:00 2001 From: Daniel Spaude Date: Fri, 10 Feb 2023 20:22:15 +0100 Subject: [PATCH] MapView: 'Mapped by' column values should always be delivered - WIP --- packages/nc-gui/composables/useViewColumns.ts | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/packages/nc-gui/composables/useViewColumns.ts b/packages/nc-gui/composables/useViewColumns.ts index b04eef76c9..02b34a5558 100644 --- a/packages/nc-gui/composables/useViewColumns.ts +++ b/packages/nc-gui/composables/useViewColumns.ts @@ -1,4 +1,4 @@ -import { isSystemColumn } from 'nocodb-sdk' +import { isSystemColumn, MapType, ViewTypes } from 'nocodb-sdk' import type { ColumnType, TableType, ViewType } from 'nocodb-sdk' import type { ComputedRef, Ref } from 'vue' import { IsPublicInj, computed, inject, ref, useNuxtApp, useProject, useUIPermission, watch } from '#imports' @@ -25,7 +25,10 @@ export function useViewColumns( () => isPublic.value || !isUIAllowed('hideAllColumns') || !isUIAllowed('showAllColumns') || isSharedBase.value, ) - const isColumnViewEssential = (column: ColumnType) => column. + const isColumnViewEssential = (column: ColumnType) => { + console.log('column', column) + return view.value?.type === ViewTypes.MAP && (view.value?.view as MapType)?.fk_geo_data_col_id === column.id + } const metaColumnById = computed>(() => { if (!meta.value?.columns) return {}