config.js 6.18 KB
Newer Older
1
import { PageTemplateView, TabsTemplateView } from '@/pages/frame/view/template';
wb-ct393452's avatar
wb-ct393452 committed
2 3 4

// 路由配置
const options = {
水落(YangLei)'s avatar
水落(YangLei) committed
5
    mode: 'history',
wb-ct393452's avatar
wb-ct393452 committed
6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29
    routes: [
        {
            path: '/login',
            name: '登录页',
            component: () => import('@/pages/frame/view/login'),
        },
        {
            path: '*',
            name: '404',
            component: () => import('@/pages/frame/view/exception/404'),
        },
        {
            path: '/403',
            name: '403',
            component: () => import('@/pages/frame/view/exception/403'),
        },
        {
            path: '/500',
            name: '500',
            component: () => import('@/pages/frame/view/exception/500'),
        },
        {
            path: '/',
            component: TabsTemplateView,
水落(YangLei)'s avatar
水落(YangLei) committed
30 31
            redirect: '/home',
            name: '首页',
wb-ct393452's avatar
wb-ct393452 committed
32
            children: [
水落(YangLei)'s avatar
水落(YangLei) committed
33 34
                {
                    path: 'home',
35
                    name: '首页',
水落(YangLei)'s avatar
水落(YangLei) committed
36 37 38
                    meta: { icon: 'home' },
                    component: () => import('@/pages/home/index.vue'),
                },
wb-ct393452's avatar
wb-ct393452 committed
39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63
                {
                    path: 'dashboard',
                    name: 'Dashboard',
                    meta: {
                        icon: 'dashboard',
                    },
                    children: [
                        {
                            path: 'workbench',
                            name: '工作台',
                            meta: {
                                page: {
                                    closable: false,
                                },
                            },
                            component: () => import('@/pages/dashboard/workbench'),
                        },
                        {
                            path: 'analysis',
                            name: '分析页',
                            component: () => import('@/pages/dashboard/analysis'),
                        },
                    ],
                },
                {
64
                    path: 'system',
wb-ct393452's avatar
wb-ct393452 committed
65 66 67 68 69 70 71 72 73 74
                    name: '系统管理',
                    meta: {
                        icon: 'setting',
                        page: {
                            cacheAble: true,
                        },
                    },
                    component: PageTemplateView,
                    children: [
                        {
75
                            path: 'menu',
wb-ct393452's avatar
wb-ct393452 committed
76 77 78 79
                            name: '菜单管理',
                            component: () => import('@/pages/system/view/menu'),
                        },
                        {
80
                            path: 'organization',
wb-ct393452's avatar
wb-ct393452 committed
81
                            name: '组织管理',
陈浩玮's avatar
陈浩玮 committed
82 83
                            children: [
                                {
84
                                    path: 'job',
陈浩玮's avatar
陈浩玮 committed
85
                                    name: '岗位管理',
陈浩玮's avatar
陈浩玮 committed
86
                                    component: () =>
陈浩玮's avatar
陈浩玮 committed
87
                                        import('@/pages/system/view/organization/jobsmanagement/Jobs.vue'),
陈浩玮's avatar
陈浩玮 committed
88 89
                                },
                                {
90
                                    path: 'user',
陈浩玮's avatar
陈浩玮 committed
91 92
                                    name: '用户管理',
                                    component: () =>
陈浩玮's avatar
陈浩玮 committed
93 94 95
                                        import('@/pages/system/view/organization/usermanagement/User.vue'),
                                },
                                {
96
                                    path: 'org',
陈浩玮's avatar
陈浩玮 committed
97 98 99
                                    name: '机构管理',
                                    component: () =>
                                        import('@/pages/system/view/organization/orgmanagement/Org.vue'),
陈浩玮's avatar
陈浩玮 committed
100 101
                                },
                            ],
wb-ct393452's avatar
wb-ct393452 committed
102 103
                        },
                        {
104
                            path: 'role',
wb-ct393452's avatar
wb-ct393452 committed
105 106 107 108
                            name: '角色管理',
                            component: () => import('@/pages/system/view/role'),
                        },
                        {
109
                            path: 'parameter',
wb-ct393452's avatar
wb-ct393452 committed
110
                            name: '参数管理',
陈浩玮's avatar
参数  
陈浩玮 committed
111 112
                            children: [
                                {
113
                                    path: 'business',
陈浩玮's avatar
参数  
陈浩玮 committed
114 115 116 117
                                    name: '业务参数',
                                    component: () =>
                                        import('@/pages/system/view/parameter/business/index.vue'),
                                },
陈浩玮's avatar
陈浩玮 committed
118
                                {
119
                                    path: 'operation',
陈浩玮's avatar
陈浩玮 committed
120 121 122 123
                                    name: '运维参数',
                                    component: () =>
                                        import('@/pages/system/view/parameter/operation/index.vue'),
                                },
陈浩玮's avatar
参数  
陈浩玮 committed
124
                            ],
wb-ct393452's avatar
wb-ct393452 committed
125 126
                        },
                        {
127
                            path: 'log',
wb-ct393452's avatar
wb-ct393452 committed
128
                            name: '日志管理',
129 130
                            children: [
                                {
131
                                    path: 'login',
132
                                    name: '登录日志',
133
                                    component: () => import('@/pages/system/view/log/login_log'),
134
                                },
135
                                {
136
                                    path: 'operation',
137 138 139
                                    name: '操作日志',
                                    component: () => import('@/pages/system/view/log/operation/index.vue'),
                                },
140
                            ],
wb-ct393452's avatar
wb-ct393452 committed
141
                        },
水落(YangLei)'s avatar
水落(YangLei) committed
142
                        {
143
                            path: 'task',
水落(YangLei)'s avatar
水落(YangLei) committed
144 145 146
                            name: '任务管理',
                            component: () => import('@/pages/system/view/task/index.vue'),
                        },
wb-ct393452's avatar
wb-ct393452 committed
147 148
                    ],
                },
水落(YangLei)'s avatar
水落(YangLei) committed
149
                {
150
                    path: 'user',
水落(YangLei)'s avatar
水落(YangLei) committed
151 152 153 154
                    name: '个人中心',
                    meta: { icon: 'user' },
                    component: () => import('@/pages/user/index.vue'),
                },
wb-ct393452's avatar
wb-ct393452 committed
155 156 157 158 159 160
            ],
        },
    ],
};

export default options;