中泽后台管理前端
Вы не можете выбрать более 25 тем Темы должны начинаться с буквы или цифры, могут содержать дефисы(-) и должны содержать не более 35 символов.

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185
  1. /**
  2. * @name umi 的路由配置
  3. * @description 只支持 path,component,routes,redirect,wrappers,name,icon 的配置
  4. * @param path path 只支持两种占位符配置,第一种是动态参数 :id 的形式,第二种是 * 通配符,通配符只能出现路由字符串的最后。
  5. * @param component 配置 location 和 path 匹配后用于渲染的 React 组件路径。可以是绝对路径,也可以是相对路径,如果是相对路径,会从 src/pages 开始找起。
  6. * @param routes 配置子路由,通常在需要为多个路径增加 layout 组件时使用。
  7. * @param redirect 配置路由跳转
  8. * @param wrappers 配置路由组件的包装组件,通过包装组件可以为当前的路由组件组合进更多的功能。 比如,可以用于路由级别的权限校验
  9. * @param name 配置路由的标题,默认读取国际化文件 menu.ts 中 menu.xxxx 的值,如配置 name 为 login,则读取 menu.ts 中 menu.login 的取值作为标题
  10. * @param icon 配置路由的图标,取值参考 https://ant.design/components/icon-cn, 注意去除风格后缀和大小写,如想要配置图标为 <StepBackwardOutlined /> 则取值应为 stepBackward 或 StepBackward,如想要配置图标为 <UserOutlined /> 则取值应为 user 或者 User
  11. * @doc https://umijs.org/docs/guides/routes
  12. */
  13. export default [
  14. {
  15. path: '/',
  16. redirect: '/user/login',
  17. },
  18. {
  19. path: '/account',
  20. routes: [
  21. {
  22. name: 'acenter',
  23. path: '/account/center',
  24. component: './User/Center',
  25. },
  26. {
  27. name: 'asettings',
  28. path: '/account/settings',
  29. component: './User/Settings',
  30. },
  31. ],
  32. },
  33. {
  34. name: 'system',
  35. path: '/system',
  36. routes: [
  37. {
  38. name: '字典数据',
  39. path: '/system/dict-data/index/:id',
  40. component: './System/DictData',
  41. },
  42. {
  43. name: '分配用户',
  44. path: '/system/role-auth/user/:id',
  45. component: './System/Role/authUser',
  46. },
  47. ],
  48. },
  49. {
  50. path: '*',
  51. layout: false,
  52. component: './404',
  53. },
  54. {
  55. path: '/user',
  56. layout: false,
  57. routes: [
  58. {
  59. name: 'login',
  60. path: '/user/login',
  61. component: './User/Login',
  62. },
  63. ],
  64. },
  65. {
  66. name: 'Home',
  67. path: '/Home',
  68. icon: 'smile',
  69. routes: [
  70. {
  71. name: 'banner',
  72. path: '/Home/banner',
  73. component: './Home/banner',
  74. },
  75. ],
  76. },
  77. {
  78. name: 'GoinZZ',
  79. path: '/GoinZZ',
  80. icon: 'smile',
  81. routes: [
  82. {
  83. name: 'structure',
  84. path: '/GoinZZ/structure',
  85. component: './GoinZZ/structure',
  86. },
  87. {
  88. name: 'developHistory',
  89. path: '/GoinZZ/developHistory',
  90. component: './GoinZZ/developHistory',
  91. },
  92. {
  93. name: 'honor',
  94. path: '/GoinZZ/honor',
  95. component: './GoinZZ/honor',
  96. },
  97. ],
  98. },
  99. {
  100. name: 'News',
  101. path: '/News',
  102. icon: 'smile',
  103. routes: [
  104. {
  105. name: 'NewsList',
  106. path: '/News/NewsList',
  107. component: './News/NewsList',
  108. },
  109. ],
  110. },
  111. {
  112. name: 'PartyWork',
  113. path: '/PartyWork',
  114. icon: 'smile',
  115. routes: [
  116. {
  117. name: 'partyWork',
  118. path: '/PartyWork/partyWork',
  119. component: './PartyWork/partyWork',
  120. },
  121. ],
  122. },
  123. {
  124. name: 'SocialRespon',
  125. path: '/SocialRespon',
  126. icon: 'smile',
  127. routes: [
  128. {
  129. name: 'socialRespon',
  130. path: '/SocialRespon/socialRespon',
  131. component: './SocialRespon/socialRespon',
  132. },
  133. ],
  134. },
  135. {
  136. name: 'JoinZZ',
  137. path: '/JoinZZ',
  138. icon: 'smile',
  139. routes: [
  140. {
  141. name: 'vacancy',
  142. path: '/JoinZZ/vacancy',
  143. component: './JoinZZ/vacancy',
  144. },
  145. {
  146. name: 'biddingDocument',
  147. path: '/JoinZZ/biddingDocument',
  148. component: './JoinZZ/biddingDocument',
  149. },
  150. ],
  151. },
  152. {
  153. name: 'Other',
  154. path: '/Other',
  155. icon: 'smile',
  156. routes: [
  157. {
  158. name: 'seo',
  159. path: '/Other/seo',
  160. component: './Other/seo',
  161. },
  162. {
  163. name: 'footer',
  164. path: '/Other/footer',
  165. component: './Other/footer',
  166. },
  167. ],
  168. },
  169. {
  170. name: 'monitor',
  171. path: '/monitor',
  172. routes: [
  173. {
  174. name: '任务日志',
  175. path: '/monitor/job-log/index/:id',
  176. component: './Monitor/JobLog',
  177. },
  178. ],
  179. },
  180. {
  181. name: 'log',
  182. path: '/log',
  183. routes: [],
  184. },
  185. ];