routes.ts 10 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444
  1. export default [
  2. {
  3. path: '/user',
  4. layout: false,
  5. routes: [
  6. {
  7. path: '/user',
  8. routes: [
  9. {
  10. name: 'login',
  11. path: '/user/login',
  12. component: './user/Login',
  13. },
  14. ],
  15. },
  16. ],
  17. },
  18. // {
  19. // path: '/analysis',
  20. // name: 'analysis',
  21. // icon: 'smile',
  22. // component: './Analysis',
  23. // },
  24. {
  25. path: '/system',
  26. name: 'system',
  27. icon: 'crown',
  28. routes: [
  29. {
  30. path: '/system',
  31. redirect: '/system/user',
  32. },
  33. {
  34. path: '/system/user',
  35. name: 'user',
  36. icon: 'smile',
  37. access: 'user',
  38. component: './system/User',
  39. },
  40. {
  41. path: '/system/department',
  42. name: 'department',
  43. icon: 'smile',
  44. component: './system/Department',
  45. },
  46. {
  47. hideInMenu: true,
  48. path: '/system/department/:id/assets',
  49. name: 'assets',
  50. icon: 'smile',
  51. component: './system/Department/Assets',
  52. },
  53. {
  54. hideInMenu: true,
  55. path: '/system/department/:id/user',
  56. name: 'member',
  57. icon: 'smile',
  58. component: './system/Department/Member',
  59. },
  60. {
  61. path: '/system/role',
  62. name: 'role',
  63. icon: 'smile',
  64. access: 'role',
  65. component: './system/Role',
  66. },
  67. {
  68. hideInMenu: true,
  69. path: '/system/role/edit/:id',
  70. name: 'role-edit',
  71. icon: 'smile',
  72. component: './system/Role/Edit',
  73. },
  74. {
  75. path: '/system/permission',
  76. name: 'permission',
  77. icon: 'smile',
  78. component: './system/Permission',
  79. },
  80. // {
  81. // path: '/system/open-api',
  82. // name: 'open-api',
  83. // icon: 'smile',
  84. // component: './system/OpenAPI',
  85. // },
  86. // {
  87. // path: '/system/tenant',
  88. // name: 'tenant',
  89. // icon: 'smile',
  90. // component: './system/Tenant',
  91. // },
  92. {
  93. hideInMenu: true,
  94. path: '/system/tenant/detail/:id',
  95. name: 'tenant-detail',
  96. icon: 'smile',
  97. component: './system/Tenant/Detail',
  98. },
  99. // {
  100. // path: '/system/datasource',
  101. // name: 'datasource',
  102. // icon: 'smile',
  103. // component: './system/DataSource',
  104. // },
  105. //
  106. ],
  107. },
  108. // {
  109. // path: '/device',
  110. // name: 'device',
  111. // icon: 'crown',
  112. // routes: [
  113. // {
  114. // path: '/device',
  115. // redirect: '/device/product',
  116. // },
  117. // {
  118. // path: '/device/product',
  119. // name: 'product',
  120. // icon: 'smile',
  121. // component: './device/Product',
  122. // },
  123. // {
  124. // path: '/device/category',
  125. // name: 'category',
  126. // icon: 'smile',
  127. // component: './device/Category',
  128. // },
  129. // {
  130. // hideInMenu: true,
  131. // path: '/device/product/detail/:id',
  132. // name: 'product-detail',
  133. // icon: 'smile',
  134. // component: './device/Product/Detail',
  135. // },
  136. // {
  137. // path: '/device/instance',
  138. // name: 'instance',
  139. // icon: 'smile',
  140. // component: './device/Instance',
  141. // },
  142. // {
  143. // hideInMenu: true,
  144. // path: '/device/instance/detail/:id',
  145. // name: 'instance-detail',
  146. // icon: 'smile',
  147. // component: './device/Instance/Detail',
  148. // },
  149. // {
  150. // path: '/device/command',
  151. // name: 'command',
  152. // icon: 'smile',
  153. // component: './device/Command',
  154. // },
  155. // {
  156. // path: '/device/firmware',
  157. // name: 'firmware',
  158. // icon: 'smile',
  159. // component: './device/Firmware',
  160. // },
  161. // {
  162. // hideInMenu: true,
  163. // path: '/device/firmware/detail/:id',
  164. // name: 'firmware-detail',
  165. // icon: 'smile',
  166. // component: './device/Firmware/Detail',
  167. // },
  168. // {
  169. // path: '/device/alarm',
  170. // name: 'alarm',
  171. // icon: 'smile',
  172. // component: './device/Alarm',
  173. // },
  174. // {
  175. // path: '/device/location',
  176. // name: 'location',
  177. // icon: 'smile',
  178. // component: './device/Location',
  179. // },
  180. // ],
  181. // },
  182. // {
  183. // path: '/link',
  184. // name: 'link',
  185. // icon: 'crown',
  186. // routes: [
  187. // {
  188. // path: '/link',
  189. // redirect: '/link/certificate',
  190. // },
  191. // {
  192. // path: '/link/certificate',
  193. // name: 'certificate',
  194. // icon: 'smile',
  195. // component: './link/Certificate',
  196. // },
  197. // {
  198. // path: '/link/protocol',
  199. // name: 'protocol',
  200. // icon: 'smile',
  201. // component: './link/Protocol',
  202. // },
  203. // {
  204. // path: 'link/type',
  205. // name: 'type',
  206. // icon: 'smile',
  207. // component: './link/Type',
  208. // },
  209. // {
  210. // path: '/link/gateway',
  211. // name: 'gateway',
  212. // icon: 'smile',
  213. // component: './link/Gateway',
  214. // },
  215. // {
  216. // path: '/link/opcua',
  217. // name: 'opcua',
  218. // icon: 'smile',
  219. // component: './link/Opcua',
  220. // },
  221. // ],
  222. // },
  223. // {
  224. // path: '/notice',
  225. // name: 'notice',
  226. // icon: 'crown',
  227. // routes: [
  228. // {
  229. // path: '/notice',
  230. // redirect: '/notice/config',
  231. // },
  232. // {
  233. // path: '/notice/config',
  234. // name: 'config',
  235. // icon: 'smile',
  236. // component: './notice/Config',
  237. // },
  238. // {
  239. // path: '/notice/template',
  240. // name: 'template',
  241. // icon: 'smile',
  242. // component: './notice/Template',
  243. // },
  244. // ],
  245. // },
  246. // {
  247. // path: '/rule-engine',
  248. // name: 'rule-engine',
  249. // icon: 'crown',
  250. // routes: [
  251. // {
  252. // path: '/rule-engine',
  253. // redirect: '/rule-engine/instance',
  254. // },
  255. // {
  256. // path: '/rule-engine/instance',
  257. // name: 'instance',
  258. // icon: 'smile',
  259. // component: './rule-engine/Instance',
  260. // },
  261. // {
  262. // path: '/rule-engine/sqlRule',
  263. // name: 'sqlRule',
  264. // icon: 'smile',
  265. // component: './rule-engine/SQLRule',
  266. // },
  267. // {
  268. // path: '/rule-engine/scene',
  269. // name: 'scene',
  270. // icon: 'smile',
  271. // component: './rule-engine/Scene',
  272. // },
  273. // ],
  274. // },
  275. // {
  276. // path: '/visualization',
  277. // name: 'visualization',
  278. // icon: 'crown',
  279. // routes: [
  280. // {
  281. // path: '/visualization',
  282. // redirect: '/visualization/category',
  283. // },
  284. // {
  285. // path: '/visualization/category',
  286. // name: 'category',
  287. // icon: 'smile',
  288. // component: './visualization/Category',
  289. // },
  290. // {
  291. // path: '/visualization/screen',
  292. // name: 'screen',
  293. // icon: 'smile',
  294. // component: './visualization/Screen',
  295. // },
  296. // {
  297. // path: '/visualization/configuration',
  298. // name: 'configuration',
  299. // icon: 'smile',
  300. // component: './visualization/Configuration',
  301. // },
  302. // ],
  303. // },
  304. // {
  305. // path: '/simulator',
  306. // name: 'simulator',
  307. // icon: 'crown',
  308. // routes: [
  309. // {
  310. // path: '/simulator',
  311. // redirect: '/simulator/device',
  312. // },
  313. // {
  314. // path: '/simulator/device',
  315. // name: 'device',
  316. // icon: 'smile',
  317. // component: './simulator/Device',
  318. // },
  319. // ],
  320. // },
  321. // {
  322. // path: '/log',
  323. // name: 'log',
  324. // icon: 'crown',
  325. // routes: [
  326. // {
  327. // path: '/log',
  328. // redirect: '/log/access',
  329. // },
  330. // {
  331. // path: '/log/access',
  332. // name: 'access',
  333. // icon: 'smile',
  334. // component: './log/Access',
  335. // },
  336. // {
  337. // path: '/log/system',
  338. // name: 'system',
  339. // icon: 'smile',
  340. // component: './log/System',
  341. // },
  342. // ],
  343. // },
  344. // {
  345. // path: '/cloud',
  346. // name: 'cloud',
  347. // icon: 'crown',
  348. // routes: [
  349. // {
  350. // path: '/cloud',
  351. // redirect: '/cloud/duer',
  352. // },
  353. // {
  354. // path: '/cloud/dueros',
  355. // name: 'DuerOS',
  356. // icon: 'smile',
  357. // component: './cloud/DuerOS',
  358. // },
  359. // {
  360. // path: '/cloud/aliyun',
  361. // name: 'aliyun',
  362. // icon: 'smile',
  363. // component: './cloud/Aliyun',
  364. // },
  365. // {
  366. // path: '/cloud/onenet',
  367. // name: 'onenet',
  368. // icon: 'smile',
  369. // component: './cloud/Onenet',
  370. // },
  371. // {
  372. // path: '/cloud/ctwing',
  373. // name: 'ctwing',
  374. // icon: 'smile',
  375. // component: './cloud/Ctwing',
  376. // },
  377. // ],
  378. // },
  379. // {
  380. // path: '/media',
  381. // name: 'media',
  382. // icon: 'crown',
  383. // routes: [
  384. // {
  385. // path: '/media',
  386. // redirect: '/media/config',
  387. // },
  388. // {
  389. // path: '/media/config',
  390. // name: 'config',
  391. // icon: 'smile',
  392. // component: './media/Config',
  393. // },
  394. // {
  395. // path: '/media/device',
  396. // name: 'device',
  397. // icon: 'smile',
  398. // component: './media/Device',
  399. // },
  400. // {
  401. // path: '/media/reveal',
  402. // name: 'reveal',
  403. // icon: 'smile',
  404. // component: './media/Reveal',
  405. // },
  406. // {
  407. // path: '/media/cascade',
  408. // name: 'cascade',
  409. // icon: 'smile',
  410. // component: './media/Cascade',
  411. // },
  412. // ],
  413. // },
  414. // {
  415. // path: '/edge',
  416. // name: 'edge',
  417. // icon: 'crown',
  418. // routes: [
  419. // {
  420. // path: '/edge',
  421. // redirect: '/edge/product',
  422. // },
  423. // {
  424. // path: '/edge/product',
  425. // name: 'product',
  426. // icon: 'smile',
  427. // component: './edge/Product',
  428. // },
  429. // {
  430. // path: '/edge/device',
  431. // name: 'device',
  432. // icon: 'smile',
  433. // component: './edge/Device',
  434. // },
  435. // ],
  436. // },
  437. {
  438. path: '/',
  439. redirect: '/system',
  440. },
  441. {
  442. component: './404',
  443. },
  444. ];