system.js 1.31 KB
import Layout from '@/layout'

const systemRouter = {
  path: '/system',
  component: Layout,
  redirect: '/system/page',
  alwaysShow: true, // will always show the root menu
  name: 'System',
  meta: {
    title: 'systems.systems',
    icon: 'component',
    roles: ['admin', 'assistant', 'runner'] // you can set roles in root nav
  },
  children: [{
    path: 'page',
    component: () => import('@/views/example/list'),
    name: 'SystemList',
    meta: {
      title: 'systems.sites',
      roles: ['admin', 'assistant', 'runner'] // or you can only set roles in sub nav
    }
  },
  {
    path: 'page',
    component: () => import('@/views/example/list'),
    name: 'SystemList',
    meta: {
      title: 'systems.money',
      roles: ['admin', 'assistant', 'runner'] // or you can only set roles in sub nav
    }
  },
  {
    path: 'page',
    component: () => import('@/views/example/list'),
    name: 'SystemList',
    meta: {
      title: 'systems.industry',
      roles: ['admin', 'assistant', 'runner'] // or you can only set roles in sub nav
    }
  },
  {
    path: 'page',
    component: () => import('@/views/example/list'),
    name: 'SystemList',
    meta: {
      title: 'systems.template',
      roles: ['admin', 'assistant', 'runner'] // or you can only set roles in sub nav
    }
  }

  ]
}

export default systemRouter