setup route for first user
This commit is contained in:
parent
91ff0835fb
commit
6d9e75bb0c
20 changed files with 455 additions and 30 deletions
|
@ -15,7 +15,7 @@
|
|||
</SidebarTemplate>
|
||||
</template>
|
||||
<template #main>
|
||||
<component v-if="activeLink?.component" :is="activeLink.component" />
|
||||
<component v-if="display" :is="displayed" />
|
||||
<div v-else class="w-full h-full bg-white rounded-lg"></div>
|
||||
</template>
|
||||
</SidebarLayout>
|
||||
|
@ -39,7 +39,22 @@ export default defineComponent({
|
|||
},
|
||||
},
|
||||
computed: {
|
||||
...mapState(useNavigationStore, ["activeNavigationObject", "activeTopLevelObject", "activeLink"]),
|
||||
...mapState(useNavigationStore, [
|
||||
"activeNavigationObject",
|
||||
"activeTopLevelObject",
|
||||
"activeLink",
|
||||
"componentOverwrite",
|
||||
]),
|
||||
display(): boolean {
|
||||
return this.activeLink?.component || this.componentOverwrite;
|
||||
},
|
||||
displayed() {
|
||||
if (this.componentOverwrite != null) {
|
||||
return this.componentOverwrite;
|
||||
} else {
|
||||
return this.activeLink?.component;
|
||||
}
|
||||
},
|
||||
},
|
||||
created() {
|
||||
this.setLink(this.activeTopLevelObject.levelDefault);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue