index.js 4.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151
  1. import { createRouter, createWebHashHistory } from 'vue-router'
  2. import Home from '../views/Home/Home.vue'
  3. const routes = [
  4. {
  5. path: '/', // 驾驶舱
  6. name: 'Home',
  7. component: Home,
  8. },
  9. {
  10. path: '/about',
  11. name: 'About',
  12. component: () => import(/* webpackChunkName: "about" */ '../views/About.vue'),
  13. },
  14. {
  15. path: '/status', // 状态监视
  16. name: 'Status',
  17. component: () => import(/* webpackChunkName: "status" */ '../views/Status/Status.vue'),
  18. },
  19. {
  20. path: '/agc', // AGC 监视
  21. name: 'Agc',
  22. component: () => import(/* webpackChunkName: "agc" */ '../views/Agc/Agc.vue'),
  23. },
  24. {
  25. path: '/windsite',
  26. name: 'WindSite',
  27. component: () => import(/* webpackChunkName: "windsite" */ '../views/WindSite/WindSite.vue'),
  28. children: [{
  29. path: 'home', // 场站监视
  30. component: () => import(/* webpackChunkName: "windsitehome" */ '../views/WindSite/pages/Home/Home.vue'),
  31. }, {
  32. path: 'draughtfanlist', // 风机列表
  33. component: () => import(/* webpackChunkName: "windsitedraughtfanlist" */ '../views/WindSite/pages/DraughtFanList.vue'),
  34. }, {
  35. path: 'matrix', // 风场矩阵
  36. component: () => import(/* webpackChunkName: "windsitematrix" */ '../views/WindSite/pages/Matrix.vue'),
  37. }, {
  38. path: 'lightmatrix',
  39. component: () => import(/* webpackChunkName: "windsitelightmatrix" */ '../views/WindSite/pages/LightMatrix.vue'),
  40. }, {
  41. path: 'box',
  42. component: () => import(/* webpackChunkName: "windsitebox" */ '../views/WindSite/pages/Box.vue'),
  43. }, {
  44. path: 'info', // 单机状态监视
  45. component: () => import(/* webpackChunkName: "windsitebox" */ '../views/WindSite/pages/Info/Info.vue'),
  46. }, {
  47. path: 'tower',
  48. component: () => import(/* webpackChunkName: "windsitetower" */ '../views/WindSite/pages/Tower.vue'),
  49. }, {
  50. path: 'inverter-info',
  51. component: () => import(/* webpackChunkName: "windsitetower" */ '../views/WindSite/pages/Inverter-Info.vue'),
  52. }, {
  53. path: 'map',
  54. component: () => import(/* webpackChunkName: "windsitemap" */ '../views/WindSite/pages/Map.vue'),
  55. }, {
  56. path: 'map1',
  57. component: () => import(/* webpackChunkName: "windsitemap1" */ '../views/WindSite/pages/Map1.vue'),
  58. }]
  59. },
  60. {
  61. path: '/lightmatrix', // 光伏明细矩阵
  62. name: 'LightMatrix',
  63. component: () => import(/* webpackChunkName: "lightmatrix" */ '../views/LightMatrix/LightMatrix.vue'),
  64. },
  65. {
  66. path: '/lightmatrix1', // 基础矩阵
  67. name: 'LightMatrix1',
  68. component: () => import(/* webpackChunkName: "lightmatrix1" */ '../views/LightMatrix1/LightMatrix1.vue'),
  69. },
  70. {
  71. path: '/lightmatrix2', // 欠发矩阵
  72. name: 'LightMatrix2',
  73. component: () => import(/* webpackChunkName: "lightmatrix2" */ '../views/LightMatrix2/LightMatrix2.vue'),
  74. }, {
  75. path: '/lightmatrix3', // 明细矩阵
  76. name: 'LightMatrix3',
  77. component: () => import(/* webpackChunkName: "lightmatrix3" */ '../views/LightMatrix3/LightMatrix3.vue'),
  78. }, {
  79. path: '/decision1',
  80. name: 'decision1',
  81. component: () => import(/* webpackChunkName: "lightmatrix3" */ '../views/Decision/Decision1.vue'),
  82. },
  83. {
  84. path: '/decision2',
  85. name: 'decision2',
  86. component: () => import(/* webpackChunkName: "lightmatrix3" */ '../views/Decision/Decision2.vue'),
  87. },
  88. {
  89. path: '/decision3',
  90. name: 'decision3',
  91. component: () => import(/* webpackChunkName: "lightmatrix3" */ '../views/Decision/Decision3.vue'),
  92. },
  93. {
  94. path: '/decision4',
  95. name: 'decision4',
  96. component: () => import(/* webpackChunkName: "lightmatrix3" */ '../views/Decision/Decision4.vue'),
  97. },
  98. {
  99. path: '/health',
  100. name: 'health',
  101. component: () => import('../views/HealthControl/Health.vue'),
  102. },
  103. {
  104. path: '/health1',
  105. name: 'health1',
  106. component: () => import('../views/HealthControl/Health1.vue'),
  107. },
  108. {
  109. path: '/health2',
  110. name: 'health2',
  111. component: () => import('../views/HealthControl/Health2.vue'),
  112. },
  113. {
  114. path: '/health3',
  115. name: 'health3',
  116. component: () => import('../views/HealthControl/Health3.vue'),
  117. },
  118. {
  119. path: '/health4',
  120. name: 'health4',
  121. component: () => import('../views/HealthControl/Health4.vue'),
  122. },
  123. {
  124. path: '/health5',
  125. name: 'health5',
  126. component: () => import('../views/HealthControl/Health5.vue'),
  127. },
  128. {
  129. path: '/health6',
  130. name: 'health6',
  131. component: () => import('../views/HealthControl/Health6.vue'),
  132. },
  133. {
  134. path: '/health7',
  135. name: 'health7',
  136. component: () => import('../views/HealthControl/Health7.vue'),
  137. },
  138. ]
  139. const router = createRouter({
  140. history: createWebHashHistory(),
  141. base: '/zhfx/',
  142. routes
  143. })
  144. router.beforeEach((to, from, next) => {
  145. next()
  146. })
  147. export default router