kra/web/config/routes.ts

96 lines
1.8 KiB
TypeScript

/**
* @name umi 的路由配置
* @description 与 GVA 保持一致的路由结构
*/
export default [
{
path: '/user',
layout: false,
routes: [
{
name: 'login',
path: '/user/login',
component: './user/login',
},
],
},
{
path: '/dashboard',
name: 'dashboard',
icon: 'dashboard',
component: './dashboard',
},
{
path: '/system',
name: 'system',
icon: 'setting',
access: 'canAdmin',
routes: [
{
path: '/system/user',
name: 'user',
icon: 'user',
component: './system/user',
},
{
path: '/system/authority',
name: 'authority',
icon: 'team',
component: './system/authority',
},
{
path: '/system/menu',
name: 'menu',
icon: 'menu',
component: './system/menu',
},
{
path: '/system/api',
name: 'api',
icon: 'api',
component: './system/api',
},
{
path: '/system/dictionary',
name: 'dictionary',
icon: 'book',
component: './system/dictionary',
},
{
path: '/system/operation',
name: 'operation',
icon: 'fileSearch',
component: './system/operation',
},
{
path: '/system/params',
name: 'params',
icon: 'control',
component: './system/params',
},
{
path: '/system/state',
name: 'state',
icon: 'monitor',
component: './system/state',
},
],
},
{
path: '/person',
name: 'person',
icon: 'idcard',
component: './person',
hideInMenu: true,
},
{
path: '/',
redirect: '/dashboard',
},
{
path: '*',
layout: false,
component: './404',
},
];