123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138 |
- import Vue from 'vue'
- import Router from 'vue-router'
- // import vantui from 'vant'
- // import 'vant/lib/index.css'
- import home from '@/components/pages/home.vue'
- import learning from '@/components/pages/learning'
- import my from '@/components/pages/my.vue'
- import find from '@/components/pages/find.vue'
- Vue.use(Router)
- export default new Router({
- routes: [
- {
- path: '/',
- name: 'Home',
- component: home,
- meta: {
- title: '家校社',
- requireAuth: '' // 是否需要判断是否登录,这里是需要判断
- }
- },
- {
- path: '/learning',
- name: 'learning',
- component: learning,
- meta: {
- title: '五育融合',
- requireAuth: true // 是否需要判断是否登录,这里是需要判断
- }
- },
- {
- path: '/my',
- name: 'my',
- component: my,
- meta: {
- title: '我的',
- requireAuth: true // 是否需要判断是否登录,这里是需要判断
- }
- },
- {
- path: '/find',
- name: 'find',
- component: find,
- meta: {
- title: '创新',
- requireAuth: true // 是否需要判断是否登录,这里是需要判断
- }
- },
- {
- path: '/Login',
- name: 'login',
- component: () => import('@/components/login'),
- meta: {
- title: '登录',
- }
- },
- {
- path: '/workDetail',
- name: 'workDetail',
- component: () => import('@/components/pages/workDetail'),
- meta: {
- title: '作业详情',
- }
- },
- {
- path: '/submitWork',
- name: 'submitWork',
- component: () => import('@/components/pages/submitWork'),
- meta: {
- title: '提交作业',
- }
- },
- {
- path: '/examine',
- name: 'examine',
- component: () => import('@/components/pages/examine'),
- meta: {
- title: '义工团审核',
- }
- },
- {
- path: '/myDetail',
- name: 'myDetail',
- component: () => import('@/components/pages/myDetail'),
- meta: {
- title: '个人资料',
- }
- },
- {
- path: '/examineWork',
- name: 'examineWork',
- component: () => import('@/components/pages/examineWork'),
- meta: {
- title: '义工任务审核',
- }
- },
- {
- path: '/release',
- name: 'release',
- component: () => import('@/components/pages/release'),
- meta: {
- title: '发布内容',
- }
- },
- {
- path: '/findDetail',
- name: 'findDetail',
- component: () => import('@/components/pages/findDetail'),
- meta: {
- title: '创新',
- }
- },
- {
- path: '/myWorkDetail',
- name: 'myWorkDetail',
- component: () => import('@/components/pages/myWorkDetail'),
- meta: {
- title: '详情',
- }
- }
- ,
- {
- path: '/learningDetail',
- name: 'learningDetail',
- component: () => import('@/components/pages/learningDetail'),
- meta: {
- title: '详情',
- }
- }
- ]
- })
- const VueRouterPush = Router.prototype.push
- Router.prototype.push = function push(to) {
- return VueRouterPush.call(this, to).catch(err => err)
- }
|