Blame view
src/router/modules/user.js
1.73 KB
3d3cdb68f auto commit the c... |
1 2 3 4 5 6 7 |
/** When your routing table is too long, you can split it into small modules**/ import Layout from '@/layout' const chartsRouter = { path: '/users', component: Layout, |
50760eab9 auto commit the c... |
8 9 |
redirect: '/users/page', alwaysShow: true, // will always show the root menu |
3d3cdb68f auto commit the c... |
10 11 |
name: 'Users', meta: { |
a6e433928 auto commit the c... |
12 |
title: 'users.people', |
50760eab9 auto commit the c... |
13 |
icon: 'peoples', |
96898eae4 auto commit the c... |
14 |
roles: ['admin', 'assistant'] // you can set roles in root nav |
3d3cdb68f auto commit the c... |
15 |
}, |
50760eab9 auto commit the c... |
16 |
children: [{ |
a6e433928 auto commit the c... |
17 |
path: 'assistant', |
50760eab9 auto commit the c... |
18 |
component: () => import('@/views/users/list'), |
a6e433928 auto commit the c... |
19 20 21 22 |
name: 'assistant', query: { test: 'ssssss' }, |
50760eab9 auto commit the c... |
23 |
meta: { |
a6e433928 auto commit the c... |
24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 |
title: 'users.assistant', roles: ['admin'] // or you can only set roles in sub nav } }, { path: 'runner', component: () => import('@/views/users/list'), name: 'runner', query: { test: 'ssssss' }, meta: { title: 'users.runner', roles: ['admin', 'assistant'] // or you can only set roles in sub nav } }, { path: 'shoper', component: () => import('@/views/users/list'), name: 'shoper', query: { test: 'ssssss' }, meta: { title: 'users.shoper', roles: ['admin', 'assistant'] // or you can only set roles in sub nav } }, { path: 'users', component: () => import('@/views/users/list'), name: 'users', query: { test: 'ssssss' }, meta: { title: 'users.user', |
96898eae4 auto commit the c... |
61 |
roles: ['admin', 'assistant'] // or you can only set roles in sub nav |
3d3cdb68f auto commit the c... |
62 |
} |
50760eab9 auto commit the c... |
63 64 65 66 67 68 69 70 71 72 |
} // ,{ // path: '/icons', // component: () => import('@/views/icons/index'), // name: 'icons', // meta: { // title: 'icons', // roles: ['admin', 'assistant', 'shoper', 'runner'] // or you can only set roles in sub nav // } // } |
3d3cdb68f auto commit the c... |
73 74 75 76 |
] } export default chartsRouter |