asyncRouter.ts 6.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306
  1. import type { RouteRecordRaw } from 'vue-router'
  2. const asyncRouter: RouteRecordRaw[] = [
  3. {
  4. path: '/home',
  5. name: 'home',
  6. component: () => import('@/views/exception/403.vue'),
  7. meta: {
  8. title: '首页',
  9. icon: 'House'
  10. }
  11. },
  12. // -- APPEND HERE --
  13. {
  14. path: 'https://jijian.sxidc.com/',
  15. name: 'jijian',
  16. component: () => ({}),
  17. meta: {
  18. title: '极简低代码',
  19. icon: 'Aim'
  20. }
  21. },
  22. {
  23. path: '/system',
  24. name: 'system',
  25. meta: {
  26. title: '系统管理',
  27. icon: 'icon-system'
  28. },
  29. children: [
  30. {
  31. path: '/system/user',
  32. name: 'systemUser',
  33. component: () => import('@/views/system/User.vue'),
  34. meta: {
  35. title: '用户管理',
  36. icon: 'user',
  37. keepAlive: true,
  38. viewName: 'User'
  39. }
  40. },
  41. {
  42. path: '/system/role',
  43. name: 'systemRole',
  44. component: () => import('@/views/system/Role.vue'),
  45. meta: {
  46. title: '角色管理',
  47. icon: 'avatar',
  48. keepAlive: true,
  49. viewName: 'Role'
  50. }
  51. },
  52. {
  53. path: '/system/dict',
  54. name: 'systemDict',
  55. component: () => import('@/views/system/Dict.vue'),
  56. meta: {
  57. title: '字典管理',
  58. icon: 'memo'
  59. }
  60. },
  61. {
  62. path: '/system/menu',
  63. name: 'systemMenu',
  64. component: () => import('@/views/system/Menu.vue'),
  65. meta: {
  66. title: '菜单管理',
  67. icon: 'menu'
  68. }
  69. },
  70. {
  71. path: '/system/area',
  72. name: 'systemArea',
  73. component: () => import('@/views/system/Area.vue'),
  74. meta: {
  75. title: '区域管理',
  76. icon: 'Reading'
  77. }
  78. },
  79. {
  80. path: '/system/configure',
  81. name: 'systemConfigure',
  82. component: () => import('@/views/system/Configure.vue'),
  83. meta: {
  84. title: '系统配置',
  85. icon: 'Edit'
  86. }
  87. }
  88. ]
  89. },
  90. {
  91. path: '/org',
  92. name: 'org',
  93. meta: {
  94. title: '组织机构',
  95. icon: 'OfficeBuilding'
  96. },
  97. children: [
  98. {
  99. path: '/org/orgList',
  100. name: 'orgList',
  101. component: () => import('@/views/org/Org.vue'),
  102. meta: {
  103. title: '机构管理',
  104. icon: 'OfficeBuilding'
  105. }
  106. }
  107. ]
  108. },
  109. {
  110. path: '/miniprogram',
  111. name: 'miniprogram',
  112. meta: {
  113. title: '小程序管理',
  114. icon: 'icon-system'
  115. },
  116. children: [
  117. {
  118. path: '/miniprogram/banner',
  119. name: 'miniBanner',
  120. component: () => import('@/views/miniprogram/Banner.vue'),
  121. meta: {
  122. title: '轮播图',
  123. icon: 'picture'
  124. }
  125. },
  126. {
  127. path: '/miniprogram/question',
  128. name: 'miniQuestion',
  129. component: () => import('@/views/miniprogram/Question.vue'),
  130. meta: {
  131. title: '常见问题',
  132. icon: 'QuestionFilled'
  133. }
  134. },
  135. {
  136. path: '/miniprogram/feedback',
  137. name: 'miniFeedback',
  138. component: () => import('@/views/miniprogram/Feedback.vue'),
  139. meta: {
  140. title: '意见反馈',
  141. icon: 'Promotion'
  142. }
  143. },
  144. {
  145. path: '/miniprogram/about',
  146. name: 'miniAbout',
  147. component: () => import('@/views/miniprogram/About.vue'),
  148. meta: {
  149. title: '关于我们',
  150. icon: 'user'
  151. }
  152. },
  153. {
  154. path: '/miniprogram/version',
  155. name: 'miniVersion',
  156. component: () => import('@/views/miniprogram/Version.vue'),
  157. meta: {
  158. title: '版本信息',
  159. icon: 'list'
  160. }
  161. }
  162. ]
  163. },
  164. {
  165. path: '/list',
  166. name: 'list',
  167. meta: {
  168. title: '列表页',
  169. icon: 'Notification'
  170. },
  171. children: [
  172. {
  173. path: '/list/cardList',
  174. name: 'cardList',
  175. component: () => import('@/views/list/CardList.vue'),
  176. meta: {
  177. title: '卡片列表',
  178. icon: 'icon-bank-card'
  179. }
  180. }
  181. ]
  182. },
  183. {
  184. path: '/form',
  185. name: 'form',
  186. meta: {
  187. title: '表单页',
  188. icon: 'Notebook'
  189. },
  190. children: [
  191. {
  192. path: '/form/basic',
  193. name: 'formBasic',
  194. component: () => import('@/views/form/Basic.vue'),
  195. meta: {
  196. title: '基础表单'
  197. }
  198. },
  199. {
  200. path: '/form/advanced',
  201. name: 'formAdvanced',
  202. component: () => import('@/views/form/Advanced.vue'),
  203. meta: {
  204. title: '高级表单'
  205. }
  206. },
  207. {
  208. path: '/form/tab',
  209. name: 'formTab',
  210. component: () => import('@/views/form/Tab.vue'),
  211. meta: {
  212. title: 'tab表单'
  213. }
  214. },
  215. {
  216. path: '/form/step',
  217. name: 'formStep',
  218. component: () => import('@/views/form/Step.vue'),
  219. meta: {
  220. title: '步骤表单'
  221. }
  222. }
  223. ]
  224. },
  225. {
  226. path: '/result',
  227. name: 'result',
  228. meta: {
  229. title: '结果页',
  230. icon: 'CircleCheck'
  231. },
  232. children: [
  233. {
  234. path: '/result/success',
  235. name: 'resultSuccess',
  236. component: () => import('@/views/result/Success.vue'),
  237. meta: {
  238. title: '成功页'
  239. }
  240. },
  241. {
  242. path: '/result/error',
  243. name: 'resultError',
  244. component: () => import('@/views/result/Error.vue'),
  245. meta: {
  246. title: '失败页'
  247. }
  248. }
  249. ]
  250. },
  251. {
  252. path: '/monitor',
  253. name: 'monitor',
  254. meta: {
  255. title: '系统监控',
  256. icon: 'Notification'
  257. },
  258. children: [
  259. {
  260. path: '/monitor/logList',
  261. name: 'logList',
  262. component: () => import('@/views/monitor/LogList.vue'),
  263. meta: {
  264. title: '日志查询',
  265. icon: 'List'
  266. }
  267. },
  268. {
  269. path: '/monitor/messageNotif',
  270. name: 'messageNotif',
  271. component: () => import('@/views/monitor/MessageNotif.vue'),
  272. meta: {
  273. title: '消息通知',
  274. icon: 'ChatRound'
  275. }
  276. }
  277. ]
  278. },
  279. {
  280. path: '/iframe',
  281. name: 'iframe',
  282. component: () => import('@/views/iframe/Iframe.vue'),
  283. meta: {
  284. title: 'iframe示例',
  285. icon: 'Notebook'
  286. }
  287. },
  288. {
  289. path: '/userInfo',
  290. name: 'userInfo',
  291. component: () => import('@/views/user/UserInfo.vue'),
  292. meta: {
  293. title: '个人中心',
  294. icon: 'House'
  295. },
  296. hidden: true
  297. },
  298. {
  299. path: '/:pathMatch(.*)*',
  300. redirect: '/exception/404',
  301. hidden: true
  302. }
  303. ]
  304. export default asyncRouter