order.js
699 Bytes
/** When your routing table is too long, you can split it into small modules**/
import Layout from '@/layout'
const orderRouter = {
path: '/orders',
component: Layout,
redirect: '/order/page',
// alwaysShow: true, // will always show the root menu
name: 'Order',
meta: {
title: 'orders',
icon: 'shopping',
roles: ['admin', 'assistant', 'runner', 'shoper'] // you can set roles in root nav
},
children: [{
path: 'orderpage',
component: () => import('@/views/order/list'),
name: 'list',
meta: {
title: 'orders',
roles: ['admin', 'assistant', 'runner', 'shoper'] // or you can only set roles in sub nav
}
}]
}
export default orderRouter