recruit.js 5.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209
  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/home/index'),
  40. name: 'mall',
  41. meta: {
  42. title: '门墩儿商城'
  43. }
  44. },
  45. {
  46. path: '/mall/goodsDetail/:id',
  47. component: () => import('@/views/mall/components/details.vue'),
  48. name: 'goodsDetail',
  49. meta: {
  50. title: '商品详情'
  51. }
  52. },
  53. {
  54. path: '/mall/pointExchange/records',
  55. component: () => import('@/views/mall/pointExchange/records.vue'),
  56. name: 'mallPointExchangeRecords',
  57. meta: {
  58. title: '积分兑换记录'
  59. }
  60. },
  61. {
  62. path: '/mall/user',
  63. redirect: '/mall/user/order',
  64. component: () => import('@/views/mall/user/index.vue'),
  65. name: 'mallUser',
  66. meta: {
  67. title: '我的'
  68. },
  69. children: [
  70. {
  71. path: '/mall/user/order',
  72. component: () => import('@/views/mall/user/order/index.vue'),
  73. name: 'mallUserOrder',
  74. meta: {
  75. title: '我的订单',
  76. enName: 'My Order',
  77. icon: 'mdi-order-bool-ascending'
  78. }
  79. },
  80. {
  81. path: '/mall/user/address',
  82. component: () => import('@/views/mall/user/address/index.vue'),
  83. name: 'mallUserAddress',
  84. meta: {
  85. title: '收货地址',
  86. enName: 'Shipping Address',
  87. icon: 'mdi-map-marker-outline'
  88. }
  89. }
  90. ]
  91. },
  92. {
  93. path: '/mall/user/order/detail/:id',
  94. component: () => import('@/views/mall/user/order/detail.vue'),
  95. show: true,
  96. meta: {
  97. title: '订单详情'
  98. }
  99. }
  100. ]
  101. },
  102. {
  103. path: '/pointsExchange',
  104. component: Layout,
  105. children: [
  106. {
  107. path: '/pointsExchange',
  108. component: () => import('@/views/mall copy/index.vue'),
  109. name: 'pointsExchange',
  110. meta: {
  111. title: '门墩儿商城'
  112. }
  113. }
  114. ]
  115. },
  116. {
  117. path: '/about',
  118. component: Layout,
  119. children: [
  120. {
  121. path: '/about',
  122. component: () => import('@/views/about/index'),
  123. name: 'about',
  124. meta: {
  125. title: '了解门墩儿'
  126. }
  127. }
  128. ]
  129. },
  130. {
  131. path: '/recruit/personal/position',
  132. component: Layout,
  133. name: 'recruit',
  134. children: [
  135. {
  136. path: '/recruit/personal/recommend',
  137. component: () => import('@/views/recruit/personal/recommend'),
  138. name: 'recommendedPositions',
  139. meta: {
  140. title: '推荐'
  141. }
  142. },
  143. {
  144. path: '/recruit/personal/position',
  145. component: () => import('@/views/recruit/personal/position'),
  146. name: 'recruitPosition',
  147. meta: {
  148. title: '职位'
  149. }
  150. },
  151. {
  152. path: '/recruit/personal/company',
  153. component: () => import('@/views/recruit/personal/company'),
  154. name: 'recruitCompany',
  155. meta: {
  156. title: '公司'
  157. }
  158. },
  159. {
  160. path: '/recruit/personal/position/details/:id',
  161. component: () => import('@/views/recruit/personal/position/components/details'),
  162. name: 'recruitPositionDetails',
  163. meta: {
  164. title: '职位详情'
  165. }
  166. }
  167. ]
  168. },
  169. {
  170. path: '/recruit/personal/company/details/:id',
  171. component: Layout,
  172. name: 'companyDetails',
  173. meta: {
  174. title: '企业详情'
  175. },
  176. children: [
  177. {
  178. path: '/recruit/personal/company/details/:id',
  179. component: () => import('@/views/recruit/personal/companyDetail/index.vue'),
  180. meta: {
  181. title: '企业详情'
  182. },
  183. }
  184. ]
  185. },
  186. {
  187. path: '/qualificationCertificate',
  188. component: Layout,
  189. children: [
  190. {
  191. path: '/qualificationCertificate',
  192. component: () => import('@/views/common/qualificationCertificate.vue'),
  193. name: 'QualificationCertificate'
  194. }
  195. ]
  196. },
  197. ]
  198. setLoginType(recruit, 'personalCommon'),
  199. setLoginType(enterprise, 'enterprise'),
  200. setLoginType(personal, 'personal')
  201. const routeArray = [
  202. ...recruit,
  203. ...enterprise,
  204. ...personal
  205. ]
  206. export default routeArray