Browse Source

chore(nc-gui): return empty string for no-label

pull/4071/head
braks 2 years ago
parent
commit
e20c6bd0db
  1. 6
      packages/nc-gui/components/erd/utils.ts

6
packages/nc-gui/components/erd/utils.ts

@ -136,15 +136,15 @@ export function useErdElements(tables: MaybeRef<TableType[]>, props: MaybeRef<Er
return colOptions.fk_parent_column_id === (type === 'mm' ? childColId : parentColId)
})
if (!parentCol || !childCol) return
if (!parentCol || !childCol) return ''
if (type === 'mm') {
if (config.showJunctionTableNames) {
if (!modelId) return undefined
if (!modelId) return ''
const mmModel = metasWithIdAsKey.value[modelId]
if (!mmModel) return undefined
if (!mmModel) return ''
if (mmModel.title !== mmModel.table_name) {
return `${mmModel.title} (${mmModel.table_name})`

Loading…
Cancel
Save