import Vue from 'vue'
import VueRouter from 'vue-router'
import Index from '../views/index.vue'
import member001 from '../views/members/member001'
import member002 from '../views/members/member002'
Vue.use(VueRouter)

const routes = [
  {
    path: '/member',
    name: 'member',
    meta: {
      title: "会员领取"
    },
    component: () => import('../views/members/member')
  }, {
    path: '/member001',
    name: 'member001',
    meta: {
      title: "领取会员"
    },
    component: member001
  }, {
    path: '/member002',
    name: 'member002',
    meta: {
      title: "领取会员"
    },
    component: member002
  }, {
    path: '/deve/linshi',
    name: 'linshi',
    meta: {
      title: "临时测试用"
    },
    component: () => import('../views/linshi.vue')
  }, {
    path: '/manual001',
    name: 'manual001',
    meta: {
      title: "流量激活指引"
    },
    component: () => import('../views/manual/manual001.vue')
  }, {
    path: '/manual002',
    name: 'manual002',
    meta: {
      title: "产品信息"
    },
    component: () => import('../views/manual/manual002.vue')
  }, {
    path: '/manual003',
    name: 'manual003',
    meta: {
      title: "随心选产品信息"
    },
    component: () => import('../views/manual/manual003.vue')
  },
  {
    path: '/manual004',
    name: 'manual004',
    meta: {
      title: "随心选产品信息(New)"
    },
    component: () => import('../views/manual/manual004.vue')
  }, {
    path: '/order001',
    name: 'order001',
    meta: {
      title: "订购记录"
    },
    component: () => import('../views/orders/order001.vue')
  },
  { //  新后台路由
    path: '/dongAo',
    name: 'dongAo',
    meta: {
      title: "冬奥专区"
    },
    component: () => import('../views/dongAo/index.vue')
  },
  { //  svga
    path: '/test',
    name: 'test',
    meta: {
      title: "svga"
    },
    component: () => import('../views/svga/index.vue')
  },
  {
    path: '/threecsone',
    name: 'threetoone',
    meta: {
      title: "腾爱优三选一会员包"
    },
    component: () => import('../views/activate/ThreeCsOne')
  },
  {
    path: '/threetoone',
    name: 'threetoone',
    meta: {
      title: "腾爱优三合一会员包"
    },
    component: () => import('../views/activate/ThreeToOne')
  },
  {
    path: '/twotoone',
    name: 'twotoone',
    meta: {
      title: "爱优二合一会员包"
    },
    component: () => import('../views/activate/TwoToOne')
  },

  // 404
  {
    path: '/servicing',
    name: 'servicing',
    meta: {
      title: "维护中..."
    },
    component: () => import('../views/404/index.vue')
  },
  {
    path: '/report',
    name: 'report',
    meta: {
      title: "维护中..."
    },
    component: () => import('../views/annualReport/index.vue')
  },
  {
    path: '/transcosmo',
    name: 'transcosmo',
    meta: {
      title: "流量会员包"
    },
    component: () => import('../views/changShi/index.vue')
  },
  {
    path: '/transcosmoLl',
    name: 'transcosmo',
    meta: {
      title: "流量会员包"
    },
    component: () => import('../views/changShi/indexLl.vue')
  },
  {
    path: '/transcosmoHy',
    name: 'transcosmo',
    meta: {
      title: "流量会员包"
    },
    component: () => import('../views/changShi/indexHy.vue')
  },
  {
    path: '/tencent',
    name: 'tencent',
    meta: {
      title: "流量会员包"
    },
    component: () => import('../views/tencentVip/index.vue')
  },
  {
    path: '/:key',
    name: 'home',
    meta: {
      title: "首页"
    },
    component: Index
  }, {
    path: '/',
    name: 'home',
    component: Index
  }, {
    //  腾讯激活单页
    path: '/tencent/page',
    name: '/tencent/page',
    meta: {
      title: "流量激活指引"
    },
    component: () => import('../views/page/jihuo-tencent.vue')
  },
  {
    //  芒果激活指引
    path: '/mangguo/page',
    name: '/mangguo/page',
    meta: {
      title: "流量激活指引"
    },
    component: () => import('../views/page/jihuo-mangguo.vue')
  },  
]
// let mode = window.location.href.indexOf("#") != -1?"hash":'history'
const router = new VueRouter({
  // mode:mode,
  routes
})
export default router
