index.js 9.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335
  1. import Vue from 'vue';
  2. import VueRouter from 'vue-router';
  3. import checkLogin from './before';
  4. Vue.use(VueRouter);
  5. const live = [
  6. {
  7. path: '/live',
  8. name: 'live_detail',
  9. component: () => import('../views/live/index.vue'),
  10. children: [
  11. {
  12. path: '/live/detail',
  13. meta: { title: '信息详情', subSite: true },
  14. name: 'live_detail',
  15. component: () => import('../views/live/detail/detail.vue'),
  16. },
  17. {
  18. path: '/live/dynamic',
  19. meta: { title: '动态监控', subSite: true },
  20. name: 'live_dynamic',
  21. component: () => import('../views/live/dynamic/index.vue'),
  22. },
  23. {
  24. path: '/live/list',
  25. meta: { title: '新闻列表', subSite: true },
  26. name: 'live_list',
  27. component: () => import('../views/live/news-list/index.vue'),
  28. },
  29. {
  30. path: '/live/img/list',
  31. meta: { title: '图片列表', subSite: true },
  32. name: 'live_img_list',
  33. component: () => import('../views/live/news-list/img-list.vue'),
  34. },
  35. {
  36. path: '/live/service',
  37. meta: { title: '创新服务', subSite: true },
  38. name: 'live_service',
  39. component: () => import('../views/live/service/index.vue'),
  40. },
  41. {
  42. path: '/live/market',
  43. meta: { title: '科技超市', subSite: true },
  44. name: 'live_market',
  45. component: () => import('../views/live/market/index.vue'),
  46. },
  47. {
  48. path: '/live/technical',
  49. meta: { title: '科技超市', subSite: true },
  50. name: 'live_technical',
  51. component: () => import('../views/live/technical/index.vue'),
  52. },
  53. {
  54. path: '/live/liveApply',
  55. meta: { title: '项目申请', subSite: true },
  56. name: 'live_apply',
  57. component: () => import('../views/live/hall/liveApply.vue'),
  58. },
  59. ],
  60. },
  61. {
  62. path: '/live/hall/index',
  63. meta: { title: '直播首页', subSite: true },
  64. name: 'live_hall_index',
  65. component: () => import('../views/live/hall/index.vue'),
  66. },
  67. {
  68. path: '/live/hall',
  69. meta: { title: '直播大厅', subSite: true },
  70. name: 'live_hall',
  71. component: () => import('../views/live/hall/hall.vue'),
  72. },
  73. {
  74. path: '/live/liveList',
  75. meta: { title: '直播中心', subSite: true },
  76. name: 'live_list',
  77. component: () => import('../views/live/hall/liveList.vue'),
  78. },
  79. {
  80. path: '/live/hallDetail',
  81. meta: { title: '直播详情', subSite: true },
  82. name: 'live_hallDetail',
  83. component: () => import('../views/live/hall/hallDetail.vue'),
  84. },
  85. {
  86. path: '/live/home',
  87. meta: { title: '直播首页', subSite: true },
  88. name: 'live_home',
  89. component: () => import('../views/live/home.vue'),
  90. },
  91. ];
  92. const routes = [
  93. {
  94. path: '/',
  95. name: 'index',
  96. component: () => import('../views/index.vue'),
  97. },
  98. // 科技政务
  99. {
  100. path: '/government/government',
  101. name: 'government',
  102. component: () => import('../views/government/government.vue'),
  103. },
  104. // 科技政务-列表
  105. {
  106. path: '/government/governmentList',
  107. name: 'governmentList',
  108. component: () => import('../views/government/governmentList.vue'),
  109. },
  110. // 科技政务-详情
  111. {
  112. path: '/government/governmentDetail',
  113. name: 'governmentDetail',
  114. component: () => import('../views/government/governmentDetail.vue'),
  115. },
  116. // 科技政策
  117. {
  118. path: '/policy/policy',
  119. name: 'policy',
  120. component: () => import('../views/policy/policy.vue'),
  121. },
  122. // 首页政策法规详情(所属科技政策,综合政策指导)
  123. {
  124. path: '/policy/lawDetail',
  125. name: 'lawDetail',
  126. component: () => import('../views/policy/lawDetail.vue'),
  127. },
  128. // 科技超市
  129. {
  130. path: '/supermaket/supermarket',
  131. name: 'supermarket',
  132. component: () => import('../views/supermaket/supermarket.vue'),
  133. },
  134. // 科技超市产品列表
  135. {
  136. path: '/supermaket/supermarketlist',
  137. name: 'supermarketlist',
  138. component: () => import('../views/supermaket/supermarketlist.vue'),
  139. },
  140. // 科技超市-高校院所
  141. {
  142. path: '/supermaket/supermarketColleges',
  143. name: 'supermarketColleges',
  144. component: () => import('../views/supermaket/supermarketColleges.vue'),
  145. },
  146. // 科技超市-科研院所
  147. {
  148. path: '/supermaket/supermarketScientific',
  149. name: 'supermarketSientific',
  150. component: () => import('../views/supermaket/supermarketScientific.vue'),
  151. },
  152. // 科技超市-科技企业
  153. {
  154. path: '/supermaket/supermarketEnterprise',
  155. name: 'supermarketEnterprise',
  156. component: () => import('../views/supermaket/supermarketEnterprise.vue'),
  157. },
  158. // 科技超市-机构团体
  159. {
  160. path: '/supermaket/supermarketGroup',
  161. name: 'supermarketGroup',
  162. component: () => import('../views/supermaket/supermarketGroup.vue'),
  163. },
  164. // 科技超市-研发服务
  165. {
  166. path: '/supermaket/supermaketService',
  167. name: 'supermaketService',
  168. component: () => import('../views/supermaket/supermaketService.vue'),
  169. },
  170. //科技超市-技术成果
  171. {
  172. path: '/supermaket/supermakettechnology',
  173. name: 'supermakettechnology',
  174. component: () => import('../views/supermaket/supermakettechnology.vue'),
  175. },
  176. // 科技超市-创新产品
  177. {
  178. path: '/supermaket/supermarketProduct',
  179. name: 'supermarketProduct',
  180. component: () => import('../views/supermaket/supermarketProduct.vue'),
  181. },
  182. // 科技超市-咨询服务
  183. {
  184. path: '/supermaket/supermarketinnovate',
  185. name: 'supermarketinnovate',
  186. component: () => import('../views/supermaket/supermarketinnovate.vue'),
  187. },
  188. //科技数据
  189. {
  190. path: '/shuju/shuju',
  191. name: 'shuju',
  192. component: () => import('../views/shuju/shuju.vue'),
  193. },
  194. {
  195. path: '/shuju/shujulist',
  196. name: 'shujulist',
  197. component: () => import('../views/shuju/shujulist.vue'),
  198. },
  199. {
  200. path: '/shuju/shujudetail',
  201. name: 'shujudetail',
  202. component: () => import('../views/shuju/shujudetail.vue'),
  203. },
  204. //科技服务
  205. {
  206. path: '/service/service',
  207. name: 'service',
  208. component: () => import('../views/service/service.vue'),
  209. },
  210. {
  211. path: '/service/servicelist',
  212. name: 'servicelist',
  213. component: () => import('../views/service/servicelist.vue'),
  214. },
  215. {
  216. path: '/service/servicedetail',
  217. name: ' servicedetail',
  218. component: () => import('../views/service/servicedetail.vue'),
  219. },
  220. // 科技资源
  221. {
  222. path: '/resource/resource',
  223. name: 'service',
  224. component: () => import('../views/resource/resource.vue'),
  225. },
  226. //登录和注册
  227. {
  228. path: '/login',
  229. meta: { title: '用户' },
  230. component: () => import('../views/login.vue'),
  231. },
  232. //科技人才
  233. {
  234. path: '/personnel/personnel',
  235. name: 'personnel',
  236. component: () => import('../views/personnel/personnel.vue'),
  237. },
  238. //科技人才投简历详情
  239. {
  240. path: '/personnel/rencai',
  241. component: () => import('../views/personnel/rencai.vue'),
  242. },
  243. //科技人才找工作详情
  244. {
  245. path: '/personnel/personnelwork',
  246. name: 'personnelwork',
  247. component: () => import('../views/personnel/personnelwork.vue'),
  248. },
  249. //科技人才找专家详情
  250. {
  251. path: '/personnel/personnelexpert',
  252. component: () => import('../views/personnel/personnelexpert.vue'),
  253. },
  254. // 科技人才找参谋详情
  255. {
  256. path: '/personnel/personnelcmdetail',
  257. component: () => import('../views/personnel/personnelcmdetail.vue'),
  258. },
  259. // 科技人才找招聘信息
  260. {
  261. path: '/personnel/recruitList',
  262. component: () => import('../views/personnel/recruitList.vue'),
  263. },
  264. // 科技人才-就业指导
  265. {
  266. path: '/personnel/guidanceList',
  267. component: () => import('../views/personnel/guidanceList.vue'),
  268. },
  269. // 科技人才-学习实践
  270. {
  271. path: '/personnel/practiceList',
  272. component: () => import('../views/personnel/practiceList.vue'),
  273. },
  274. // 科技人才-勤工俭学
  275. {
  276. path: '/personnel/diligenceList',
  277. component: () => import('../views/personnel/diligenceList.vue'),
  278. },
  279. // 科技人才-工作顾问
  280. {
  281. path: '/personnel/adviserList',
  282. component: () => import('../views/personnel/adviserList.vue'),
  283. },
  284. //企业-基本信息
  285. {
  286. path: '/enterprise/enterprisejb',
  287. name: 'enterprisefabu',
  288. component: () => import('../views/enterprise/enterprisejb.vue'),
  289. },
  290. //企业-信息管理
  291. {
  292. path: '/enterprise/enterprisexx',
  293. name: 'enterprisexuqiu',
  294. component: () => import('../views/enterprise/enterprisexx.vue'),
  295. },
  296. //企业-发布信息列表
  297. {
  298. path: '/enterprise/enterprisefabu',
  299. name: 'enterprisefabu',
  300. component: () => import('../views/enterprise/enterprisefabu.vue'),
  301. },
  302. // 企业-需求发布
  303. {
  304. path: '/enterprise/enterprisexuqiu',
  305. name: 'enterprisexuqiu',
  306. component: () => import('../views/enterprise/enterprisexuqiu.vue'),
  307. },
  308. //企业-订购
  309. {
  310. path: '/enterprise/enterprisedg',
  311. name: 'enterprisedg',
  312. component: () => import('../views/enterprise/enterprisedg.vue'),
  313. },
  314. // 外审管理员
  315. {
  316. path: '/trial/index',
  317. name: 'trial',
  318. component: () => import('../views/trial/index.vue'),
  319. },
  320. ...live,
  321. ];
  322. const router = new VueRouter({
  323. mode: 'history',
  324. base: process.env.NODE_ENV === 'development' ? '/' : process.env.VUE_APP_ROUTER,
  325. routes,
  326. });
  327. checkLogin(router);
  328. export default router;