You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

70 lines
1.8 KiB

import Vue from 'vue'
import Router from 'vue-router'
Vue.use(Router)
// 页面路由(独立页面)
const pageRoutes = [
7 months ago
{ path: '/', redirect: '/login' },
{
path: '/login',
component: () => import('@/page-subspecialty/views/login'),
name: 'login',
meta: { title: '登录' }
},
{
path: '/question',
component: () => import('@/page-subspecialty/views/question'),
name: 'question',
meta: { title: '问卷调查' }
},
{
path: '/questionEyehistory',
component: () => import('@/page-subspecialty/views/questionEyehistory'),
name: 'question',
meta: { title: '眼科病史问卷调查' }
},
{
path: '/jmjlQuestionEyehistory',
component: () => import('@/page-subspecialty/views/jmjlQuestionEyehistory'),
name: 'question',
meta: { title: '交联眼科病史问卷调查' }
},{
path: '/complete',
component: () => import('@/page-subspecialty/views/complete'),
name: 'complete',
meta: { title: '调查完成' }
},
7 months ago
// 部署时注销掉
{
path: '/article',
component: () => import('@/page-subspecialty/views/article'),
name: 'article',
meta: { title: '文章' }
},
{
path: '/articleList',
component: () => import('@/page-subspecialty/views/articleList'),
name: 'articleList',
meta: { title: '文章列表' }
}, {
path: '/editor',
component: () => import('@/page-subspecialty/views/editor'),
name: 'editor',
meta: { title: '编辑器' }
}
]
const router = new Router({
mode: 'history',
7 months ago
// base: process.env.NODE_ENV === 'production' ? process.env.VUE_APP_BASE_HOUZHUI : '/', // 公司内部环境打开--浏览器基础路径
routes: pageRoutes
})
router.beforeEach((to, from, next) => {
// to and from are both route objects. must call `next`.
next()
})
export default router