|
|
@ -1,4 +1,4 @@ |
|
|
|
import { isSystemColumn } from "nocodb-sdk"; |
|
|
|
import { isSystemColumn } from 'nocodb-sdk' |
|
|
|
import type { ColumnType, FormType, GalleryType, GridType, TableType } from 'nocodb-sdk' |
|
|
|
import type { ColumnType, FormType, GalleryType, GridType, TableType } from 'nocodb-sdk' |
|
|
|
import type { Ref } from 'vue' |
|
|
|
import type { Ref } from 'vue' |
|
|
|
import { useNuxtApp } from '#app' |
|
|
|
import { useNuxtApp } from '#app' |
|
|
@ -20,7 +20,6 @@ export default function ( |
|
|
|
|
|
|
|
|
|
|
|
const filterQuery = ref('') |
|
|
|
const filterQuery = ref('') |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
const { $api } = useNuxtApp() |
|
|
|
const { $api } = useNuxtApp() |
|
|
|
|
|
|
|
|
|
|
|
const loadViewColumns = async () => { |
|
|
|
const loadViewColumns = async () => { |
|
|
@ -99,7 +98,6 @@ export default function ( |
|
|
|
|
|
|
|
|
|
|
|
const filteredFieldList = computed(() => { |
|
|
|
const filteredFieldList = computed(() => { |
|
|
|
return fields.value?.filter((field) => { |
|
|
|
return fields.value?.filter((field) => { |
|
|
|
|
|
|
|
|
|
|
|
// hide system columns if not enabled
|
|
|
|
// hide system columns if not enabled
|
|
|
|
if (!showSystemFields.value && isSystemColumn(metaColumnById?.value?.[field.fk_column_id as string])) { |
|
|
|
if (!showSystemFields.value && isSystemColumn(metaColumnById?.value?.[field.fk_column_id as string])) { |
|
|
|
return false |
|
|
|
return false |
|
|
@ -109,7 +107,6 @@ export default function ( |
|
|
|
}) |
|
|
|
}) |
|
|
|
}) |
|
|
|
}) |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
const sortedAndFilteredFields = computed<ColumnType[]>(() => { |
|
|
|
const sortedAndFilteredFields = computed<ColumnType[]>(() => { |
|
|
|
return (fields?.value |
|
|
|
return (fields?.value |
|
|
|
?.filter((c) => { |
|
|
|
?.filter((c) => { |
|
|
@ -123,7 +120,6 @@ export default function ( |
|
|
|
?.map((c) => metaColumnById?.value?.[c.fk_column_id as string]) || []) as ColumnType[] |
|
|
|
?.map((c) => metaColumnById?.value?.[c.fk_column_id as string]) || []) as ColumnType[] |
|
|
|
}) |
|
|
|
}) |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
return { |
|
|
|
return { |
|
|
|
fields, |
|
|
|
fields, |
|
|
|
loadViewColumns, |
|
|
|
loadViewColumns, |
|
|
|