recruit.js 3.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129
  1. // 门墩儿招聘
  2. import enterprise from './components/recruit/enterprise'
  3. import personal from './components/recruit/personal'
  4. import Layout from '@/layout'
  5. import { setLoginType } from '@/utils/loginType'
  6. const recruit = [
  7. // {
  8. // path: '/home',
  9. // redirect: '/recruitHome'
  10. // },
  11. {
  12. path: '/recruit',
  13. redirect: '/recruitHome'
  14. },
  15. {
  16. path: '/personal', // 不可删 // 个人账号登录时,缺省只能访问个人账号路由和不需要登录,防止用户在地址栏直接输入地址访问其他页面(不可删,permission中用到)
  17. redirect: '/recruitHome'
  18. },
  19. {
  20. path: '/recruitHome',
  21. component: Layout,
  22. children: [
  23. {
  24. path: '/recruitHome',
  25. component: () => import('@/views/recruit/personal/home'),
  26. name: 'recruitHome',
  27. meta: {
  28. title: '首页'
  29. }
  30. }
  31. ]
  32. },
  33. {
  34. path: '/mall',
  35. component: Layout,
  36. children: [
  37. {
  38. path: '/mall',
  39. component: () => import('@/views/mall/index'),
  40. name: 'mall',
  41. meta: {
  42. title: '甄选商城'
  43. }
  44. }
  45. ]
  46. },
  47. {
  48. path: '/about',
  49. component: Layout,
  50. children: [
  51. {
  52. path: '/about',
  53. component: () => import('@/views/about/index'),
  54. name: 'about',
  55. meta: {
  56. title: '了解门墩儿'
  57. }
  58. }
  59. ]
  60. },
  61. {
  62. path: '/recruit/personal/position',
  63. component: Layout,
  64. name: 'recruit',
  65. children: [
  66. {
  67. path: '/recruit/personal/recommend',
  68. component: () => import('@/views/recruit/personal/recommend'),
  69. name: 'recommendedPositions',
  70. meta: {
  71. title: '推荐'
  72. }
  73. },
  74. {
  75. path: '/recruit/personal/position',
  76. component: () => import('@/views/recruit/personal/position'),
  77. name: 'recruitPosition',
  78. meta: {
  79. title: '职位'
  80. }
  81. },
  82. {
  83. path: '/recruit/personal/company',
  84. component: () => import('@/views/recruit/personal/company'),
  85. name: 'recruitCompany',
  86. meta: {
  87. title: '公司'
  88. }
  89. },
  90. {
  91. path: '/recruit/personal/position/details/:id',
  92. component: () => import('@/views/recruit/personal/position/components/details'),
  93. name: 'recruitPositionDetails',
  94. meta: {
  95. title: '职位详情'
  96. }
  97. }
  98. ]
  99. },
  100. {
  101. path: '/recruit/personal/company/details/:id',
  102. component: Layout,
  103. name: 'companyDetails',
  104. meta: {
  105. title: '企业详情'
  106. },
  107. children: [
  108. {
  109. path: '/recruit/personal/company/details/:id',
  110. component: () => import('@/views/recruit/enterprise/components/enterpriseDetails.vue'),
  111. meta: {
  112. title: '企业详情'
  113. },
  114. }
  115. ]
  116. }
  117. ]
  118. setLoginType(recruit, 'personalCommon'),
  119. setLoginType(enterprise, 'enterprise'),
  120. setLoginType(personal, 'personal')
  121. const routeArray = [
  122. ...recruit,
  123. ...enterprise,
  124. ...personal
  125. ]
  126. export default routeArray