This commit is contained in:
2019-12-16 23:23:40 +00:00
parent 4005075539
commit 9340564e72
2 changed files with 73 additions and 28 deletions

View File

@@ -3,38 +3,76 @@
<gznotify ref="gznotify"></gznotify>
<gzconfirm ref="gzconfirm"></gzconfirm>
<!-- <gztest ref="gztest"></gztest> -->
<v-navigation-drawer v-if="isAuthenticated" v-model="drawer" app>
<v-list dense>
<template v-for="item in navItems">
<!-- TOP LEVEL can be holders or actions -->
<template v-if="!item.route">
<v-navigation-drawer
v-if="isAuthenticated"
v-model="drawer"
app
width="300"
>
<v-card class="mx-auto" width="300">
<v-list dense>
<template v-for="item in navItems">
<!-- TOP LEVEL can be holders or actions -->
<!-- TOP LEVEL HOLDER -->
<v-list-group
:prepend-icon="'fa-' + item.icon"
value="true"
:key="item.key"
>
<template v-slot:activator>
<v-list-item-title>{{ item.title }}</v-list-item-title>
</template>
<template v-for="subitem in item.navItems">
<template v-if="!subitem.route">
<!-- SECOND LEVEL HOLDER CONTAINS ONLY ACTIONS -->
{{ subitem.title }}
<template v-if="!item.route">
<v-list-group
:prepend-icon="'fa-' + item.icon"
value="true"
:key="item.key"
>
<template v-slot:activator>
<!--group activator -->
<v-list-item-title>{{ item.title }}</v-list-item-title>
</template>
<template v-else>
<!-- SECOND LEVEL ACTION -->
</template>
</template>
</v-list-group>
</template>
<!-- TOP LEVEL HOLDER SUBITEMS -->
<template v-for="subitem in item.navItems">
<template v-if="!subitem.route">
<!-- SECOND LEVEL HOLDER -->
<v-list-group
no-action
sub-group
value="true"
:key="subitem.key"
>
<!-- Second level activator -->
<template v-slot:activator>
<v-list-item-content>
<v-list-item-title>{{
subitem.title
}}</v-list-item-title>
</v-list-item-content>
</template>
<v-list-item
v-for="subsub in subitem.navItems"
:key="subsub.key"
:to="subsub.route"
link
>
<v-list-item-title
v-text="subsub.title"
></v-list-item-title>
<v-list-item-icon>
<v-icon>{{ "fa-" + subsub.icon }}</v-icon>
</v-list-item-icon>
</v-list-item>
</v-list-group>
</template>
<template v-else>
<!-- SECOND LEVEL ACTION -->
</template>
</template>
</v-list-group>
<!-- END OF TOP LEVEL HOLDER -->
</template>
<template v-else>
<!-- TOP LEVEL ACTION -->
<template v-else> </template>
</template>
</template>
<!-- <v-list-item
<!-- <v-list-item
v-for="item in navItems"
:key="item.route"
:to="item.route"
@@ -46,7 +84,8 @@
<v-list-item-title>{{ item.title }}</v-list-item-title>
</v-list-item-content>
</v-list-item> -->
</v-list>
</v-list>
</v-card>
</v-navigation-drawer>
<v-app-bar
v-if="isAuthenticated"

View File

@@ -48,8 +48,14 @@ export default {
coreKeys: [
//main nav options
"Home",
"DashboardDashboard",
"Schedule",
"Locale",
"SetLoginPassword",
"NotifySubscriptionList",
"UserPreferences",
"Service",
"Dispatch",
//"Dispatch",
"Inventory",
"Accounting",
"Administration",