Browse Source

Merge pull request #3257 from nocodb/fix/gui-v2-includeM2M

fix(gui-v2): includeM2M display
pull/3254/head
Raju Udava 2 years ago committed by GitHub
parent
commit
22b342545c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 3
      packages/nc-gui-v2/components/dashboard/settings/UIAcl.vue
  2. 15
      packages/nocodb/src/lib/meta/api/tableApis.ts

3
packages/nc-gui-v2/components/dashboard/settings/UIAcl.vue

@ -32,8 +32,7 @@ async function loadTableList() {
isLoading = true
tables = await $api.project.modelVisibilityList(project.value?.id, {
// FIXME: type
includeM2M: includeM2M.value || '',
includeM2M: includeM2M.value,
})
} catch (e) {
console.error(e)

15
packages/nocodb/src/lib/meta/api/tableApis.ts

@ -77,14 +77,13 @@ export async function tableList(req: Request, res: Response<TableListType>) {
})
).filter((t) => tableViewMapping[t.id]);
res // todo: pagination
.json(
new PagedResponseImpl(
req.query?.includeM2M
? tableList
: (tableList.filter((t) => !t.mm) as Model[])
)
);
res.json(
new PagedResponseImpl(
req.query?.includeM2M === 'true'
? tableList
: (tableList.filter((t) => !t.mm) as Model[])
)
);
}
export async function tableCreate(req: Request<any, any, TableReqType>, res) {

Loading…
Cancel
Save