Browse Source

Merge pull request #7822 from nocodb/nc-fix/incorrect-route-query-params

Nc fix(nc-gui): Incorrect route when navigating to view after visiting base members page
pull/7818/head
Raju Udava 9 months ago committed by GitHub
parent
commit
1ad4b079f1
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
  1. 10
      packages/nc-gui/composables/useTableNew.ts

10
packages/nc-gui/composables/useTableNew.ts

@ -86,10 +86,7 @@ export function useTableNew(param: { onTableCreate?: (tableMeta: TableType) => v
const navigateToTable = async () => {
if (openedViewsTab.value === 'view') {
await navigateTo({
path: `/${workspaceIdOrType}/${baseIdOrBaseId}/${table?.id}`,
query: route.value.query,
})
await navigateTo(`/${workspaceIdOrType}/${baseIdOrBaseId}/${table?.id}`)
}
table.isViewsLoading = true
@ -102,10 +99,7 @@ export function useTableNew(param: { onTableCreate?: (tableMeta: TableType) => v
// find the default view and navigate to it, if not found navigate to the first one
const defaultView = views.find((v) => v.is_default) || views[0]
await navigateTo({
path: `/${workspaceIdOrType}/${baseIdOrBaseId}/${table?.id}/${defaultView.id}/${openedViewsTab.value}`,
query: route.value.query,
})
await navigateTo(`/${workspaceIdOrType}/${baseIdOrBaseId}/${table?.id}/${defaultView.id}/${openedViewsTab.value}`)
}
} catch (e) {
console.error(e)

Loading…
Cancel
Save