forked from verdnatura/salix-front
feat #7311: enable leftmenu option
This commit is contained in:
parent
e3a36c0ab1
commit
01bedb94d0
|
@ -0,0 +1,174 @@
|
|||
import { RouterView } from 'vue-router';
|
||||
|
||||
export default {
|
||||
path: '/account',
|
||||
name: 'Account',
|
||||
meta: {
|
||||
title: 'accounts',
|
||||
icon: 'vn:account',
|
||||
moduleName: 'Account',
|
||||
},
|
||||
component: RouterView,
|
||||
redirect: { name: 'AccountMain' },
|
||||
menus: {
|
||||
main: ['AccountList', 'AccountDepartment'],
|
||||
card: [
|
||||
'AccountBasicData',
|
||||
'AccountNotes',
|
||||
'AccountPda',
|
||||
'AccountNotificationsManager',
|
||||
'AccountPBX',
|
||||
'AccountLog',
|
||||
'AccountCalendar',
|
||||
'AccountDms',
|
||||
'AccountTimeControl',
|
||||
],
|
||||
departmentCard: ['BasicData'],
|
||||
},
|
||||
children: [
|
||||
{
|
||||
path: '',
|
||||
name: 'AccountMain',
|
||||
component: () => import('src/pages/Account/AccountMain.vue'),
|
||||
redirect: { name: 'AccountList' },
|
||||
children: [
|
||||
{
|
||||
path: 'list',
|
||||
name: 'AccountList',
|
||||
meta: {
|
||||
title: 'list',
|
||||
icon: 'view_list',
|
||||
},
|
||||
component: () => import('src/pages/Account/AccountList.vue'),
|
||||
},
|
||||
{
|
||||
path: 'department',
|
||||
name: 'AccountDepartment',
|
||||
meta: {
|
||||
title: 'department',
|
||||
icon: 'vn:greuge',
|
||||
},
|
||||
component: () => import('src/pages/Account/AccountDepartment.vue'),
|
||||
},
|
||||
{
|
||||
path: 'create',
|
||||
name: 'AccountCreate',
|
||||
meta: {
|
||||
title: 'accountCreate',
|
||||
icon: 'add',
|
||||
},
|
||||
component: () => import('src/pages/Account/AccountCreate.vue'),
|
||||
},
|
||||
],
|
||||
},
|
||||
{
|
||||
name: 'AccountCard',
|
||||
path: ':id',
|
||||
component: () => import('src/pages/Account/Card/AccountCard.vue'),
|
||||
redirect: { name: 'AccountSummary' },
|
||||
children: [
|
||||
{
|
||||
name: 'AccountSummary',
|
||||
path: 'summary',
|
||||
meta: {
|
||||
title: 'summary',
|
||||
icon: 'launch',
|
||||
},
|
||||
component: () => import('src/pages/Account/Card/AccountSummary.vue'),
|
||||
},
|
||||
{
|
||||
path: 'basic-data',
|
||||
name: 'AccountBasicData',
|
||||
meta: {
|
||||
title: 'basicData',
|
||||
icon: 'vn:settings',
|
||||
},
|
||||
component: () =>
|
||||
import('src/pages/Account/Card/AccountBasicData.vue'),
|
||||
},
|
||||
{
|
||||
path: 'notes',
|
||||
name: 'NotesCard',
|
||||
redirect: { name: 'AccountNotes' },
|
||||
children: [
|
||||
{
|
||||
path: '',
|
||||
name: 'AccountNotes',
|
||||
meta: {
|
||||
title: 'notes',
|
||||
icon: 'vn:notes',
|
||||
},
|
||||
component: () =>
|
||||
import('src/pages/Account/Card/AccountNotes.vue'),
|
||||
},
|
||||
],
|
||||
},
|
||||
{
|
||||
name: 'AccountPda',
|
||||
path: 'pda',
|
||||
meta: {
|
||||
title: 'pda',
|
||||
icon: 'phone_android',
|
||||
},
|
||||
component: () => import('src/pages/Account/Card/AccountPda.vue'),
|
||||
},
|
||||
{
|
||||
name: 'AccountNotificationsManager',
|
||||
path: 'notifications',
|
||||
meta: {
|
||||
title: 'notifications',
|
||||
icon: 'notifications',
|
||||
},
|
||||
component: () =>
|
||||
import('src/pages/Account/Card/AccountNotificationsManager.vue'),
|
||||
},
|
||||
{
|
||||
path: 'pbx',
|
||||
name: 'AccountPBX',
|
||||
meta: {
|
||||
title: 'pbx',
|
||||
icon: 'vn:pbx',
|
||||
},
|
||||
component: () => import('src/pages/Account/Card/AccountPBX.vue'),
|
||||
},
|
||||
{
|
||||
name: 'AccountDms',
|
||||
path: 'dms',
|
||||
meta: {
|
||||
title: 'dms',
|
||||
icon: 'cloud_upload',
|
||||
},
|
||||
component: () => import('src/pages/Account/Card/AccountDms.vue'),
|
||||
},
|
||||
{
|
||||
name: 'AccountLog',
|
||||
path: 'log',
|
||||
meta: {
|
||||
title: 'log',
|
||||
icon: 'vn:History',
|
||||
},
|
||||
component: () => import('src/pages/Account/Card/AccountLog.vue'),
|
||||
},
|
||||
{
|
||||
name: 'AccountCalendar',
|
||||
path: 'calendar',
|
||||
meta: {
|
||||
title: 'calendar',
|
||||
icon: 'calendar_today',
|
||||
},
|
||||
component: () => import('src/pages/Account/Card/AccountCalendar.vue'),
|
||||
},
|
||||
{
|
||||
name: 'AccountTimeControl',
|
||||
path: 'time-control',
|
||||
meta: {
|
||||
title: 'timeControl',
|
||||
icon: 'access_time',
|
||||
},
|
||||
component: () =>
|
||||
import('src/pages/Account/Card/AccountTimeControl.vue'),
|
||||
},
|
||||
],
|
||||
},
|
||||
],
|
||||
};
|
|
@ -18,6 +18,7 @@ import Parking from './parking';
|
|||
import Agency from './agency';
|
||||
import ItemType from './itemType';
|
||||
import Zone from './zone';
|
||||
import Account from './account';
|
||||
|
||||
export default [
|
||||
Item,
|
||||
|
@ -40,4 +41,5 @@ export default [
|
|||
Agency,
|
||||
ItemType,
|
||||
Zone,
|
||||
Account,
|
||||
];
|
||||
|
|
|
@ -18,6 +18,7 @@ import roadmap from 'src/router/modules/roadmap';
|
|||
import parking from 'src/router/modules/parking';
|
||||
import agency from 'src/router/modules/agency';
|
||||
import zone from 'src/router/modules/zone';
|
||||
import account from './modules/account';
|
||||
|
||||
const routes = [
|
||||
{
|
||||
|
@ -77,6 +78,7 @@ const routes = [
|
|||
agency,
|
||||
ItemType,
|
||||
zone,
|
||||
account,
|
||||
{
|
||||
path: '/:catchAll(.*)*',
|
||||
name: 'NotFound',
|
||||
|
|
|
@ -22,6 +22,7 @@ export const useNavigationStore = defineStore('navigationStore', () => {
|
|||
'worker',
|
||||
'wagon',
|
||||
'zone',
|
||||
'account',
|
||||
];
|
||||
const pinnedModules = ref([]);
|
||||
const role = useRole();
|
||||
|
|
Loading…
Reference in New Issue