diff --git a/packages/builder/src/database/ModelDataTable/ModelDataTable.svelte b/packages/builder/src/database/ModelDataTable/ModelDataTable.svelte index 9a9a81b86f..6ac539282c 100644 --- a/packages/builder/src/database/ModelDataTable/ModelDataTable.svelte +++ b/packages/builder/src/database/ModelDataTable/ModelDataTable.svelte @@ -11,6 +11,7 @@ map, remove, keys, + takeRight } from "lodash/fp" import Select from "../../common/Select.svelte" import { getIndexSchema } from "../../common/core" @@ -78,8 +79,8 @@ function drillIntoRecord(record) { backendUiStore.update(state => { + state.breadcrumbs = [...state.breadcrumbs, record.type, record.id] state.selectedRecord = record - state.breadcrumbs = [state.selectedDatabase.name, record.id] state.selectedView = childViewsForRecord($store.hierarchy)[0] return state }) @@ -94,7 +95,7 @@
-

{last($backendUiStore.breadcrumbs)}

+

{takeRight(2, $backendUiStore.breadcrumbs).join(" / ")}