remaining.ts 22 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861
  1. import { Layout } from '@/utils/routerHelper'
  2. const { t } = useI18n()
  3. /**
  4. * redirect: noredirect 当设置 noredirect 的时候该路由在面包屑导航中不可被点击
  5. * name:'router-name' 设定路由的名字,一定要填写不然使用<keep-alive>时会出现各种问题
  6. * meta : {
  7. hidden: true 当设置 true 的时候该路由不会再侧边栏出现 如404,login等页面(默认 false)
  8. alwaysShow: true 当你一个路由下面的 children 声明的路由大于1个时,自动会变成嵌套的模式,
  9. 只有一个时,会将那个子路由当做根路由显示在侧边栏,
  10. 若你想不管路由下面的 children 声明的个数都显示你的根路由,
  11. 你可以设置 alwaysShow: true,这样它就会忽略之前定义的规则,
  12. 一直显示根路由(默认 false)
  13. title: 'title' 设置该路由在侧边栏和面包屑中展示的名字
  14. icon: 'svg-name' 设置该路由的图标
  15. noCache: true 如果设置为true,则不会被 <keep-alive> 缓存(默认 false)
  16. breadcrumb: false 如果设置为false,则不会在breadcrumb面包屑中显示(默认 true)
  17. affix: true 如果设置为true,则会一直固定在tag项中(默认 false)
  18. noTagsView: true 如果设置为true,则不会出现在tag中(默认 false)
  19. activeMenu: '/dashboard' 显示高亮的路由路径
  20. followAuth: '/dashboard' 跟随哪个路由进行权限过滤
  21. canTo: true 设置为true即使hidden为true,也依然可以进行路由跳转(默认 false)
  22. }
  23. **/
  24. const remainingRouter: AppRouteRecordRaw[] = [
  25. {
  26. path: '/redirect',
  27. component: Layout,
  28. name: 'Redirect',
  29. children: [
  30. {
  31. path: '/redirect/:path(.*)',
  32. name: 'Redirect',
  33. component: () => import('@/views/Redirect/Redirect.vue'),
  34. meta: {}
  35. }
  36. ],
  37. meta: {
  38. hidden: true,
  39. noTagsView: true
  40. }
  41. },
  42. {
  43. path: '/',
  44. component: Layout,
  45. redirect: '/index',
  46. name: 'Home',
  47. meta: {},
  48. children: [
  49. {
  50. path: 'index',
  51. component: () => import('@/views/Home/Index.vue'),
  52. name: 'Index',
  53. meta: {
  54. title: t('router.home'),
  55. icon: 'ep:home-filled',
  56. noCache: false,
  57. affix: true
  58. }
  59. }
  60. ]
  61. },
  62. {
  63. path: '/iotpms/iotdevicepms', // 商品中心
  64. component: Layout,
  65. name: 'PmsDeviceCenter',
  66. meta: {
  67. hidden: true
  68. },
  69. children: [
  70. {
  71. path: 'device/detail/add',
  72. component: () => import('@/views/pms/device/IotDeviceForm.vue'),
  73. name: 'DeviceDetailAdd',
  74. meta: {
  75. noCache: false,
  76. hidden: true,
  77. canTo: true,
  78. icon: 'ep:add',
  79. title: '设备台账添加',
  80. activeMenu: '/device/base'
  81. }
  82. },
  83. {
  84. path: 'device/detail/edit/:id(\\d+)',
  85. component: () => import('@/views/pms/device/IotDeviceForm.vue'),
  86. name: 'DeviceDetailEdit',
  87. meta: {
  88. noCache: true,
  89. hidden: true,
  90. canTo: true,
  91. icon: 'ep:edit',
  92. title: '设备台账编辑',
  93. activeMenu: '/device/base'
  94. }
  95. },{
  96. path: 'device/detail/:row',
  97. component: () => import('@/views/pms/device/DeviceInfo.vue'),
  98. name: 'DeviceDetailInfo',
  99. meta: {
  100. noCache: false,
  101. hidden: true,
  102. canTo: true,
  103. icon: 'ep:info',
  104. title: '设备台账详情',
  105. activeMenu: '/device/info'
  106. }
  107. },{
  108. path: 'device/upload/:id',
  109. component: () => import('@/views/pms/device/DeviceUpload.vue'),
  110. name: 'DeviceUpload',
  111. meta: {
  112. noCache: false,
  113. hidden: true,
  114. canTo: true,
  115. icon: 'ep:info',
  116. title: '设备台账资料上传',
  117. activeMenu: '/device/upload'
  118. }
  119. },
  120. ]
  121. },
  122. {
  123. path: '/user',
  124. component: Layout,
  125. name: 'UserInfo',
  126. meta: {
  127. hidden: true
  128. },
  129. children: [
  130. {
  131. path: 'profile',
  132. component: () => import('@/views/Profile/Index.vue'),
  133. name: 'Profile',
  134. meta: {
  135. canTo: true,
  136. hidden: true,
  137. noTagsView: false,
  138. icon: 'ep:user',
  139. title: t('common.profile')
  140. }
  141. },
  142. {
  143. path: 'notify-message',
  144. component: () => import('@/views/system/notify/my/index.vue'),
  145. name: 'MyNotifyMessage',
  146. meta: {
  147. canTo: true,
  148. hidden: true,
  149. noTagsView: false,
  150. icon: 'ep:message',
  151. title: '我的站内信'
  152. }
  153. }
  154. ]
  155. },
  156. {
  157. path: '/dict',
  158. component: Layout,
  159. name: 'dict',
  160. meta: {
  161. hidden: true
  162. },
  163. children: [
  164. {
  165. path: 'type/data/:dictType',
  166. component: () => import('@/views/system/dict/data/index.vue'),
  167. name: 'SystemDictData',
  168. meta: {
  169. title: '字典数据',
  170. noCache: true,
  171. hidden: true,
  172. canTo: true,
  173. icon: '',
  174. activeMenu: '/system/dict'
  175. }
  176. }
  177. ]
  178. },
  179. {
  180. path: '/codegen',
  181. component: Layout,
  182. name: 'CodegenEdit',
  183. meta: {
  184. hidden: true
  185. },
  186. children: [
  187. {
  188. path: 'edit',
  189. component: () => import('@/views/infra/codegen/EditTable.vue'),
  190. name: 'InfraCodegenEditTable',
  191. meta: {
  192. noCache: true,
  193. hidden: true,
  194. canTo: true,
  195. icon: 'ep:edit',
  196. title: '修改生成配置',
  197. activeMenu: 'infra/codegen/index'
  198. }
  199. }
  200. ]
  201. },
  202. {
  203. path: '/job',
  204. component: Layout,
  205. name: 'JobL',
  206. meta: {
  207. hidden: true
  208. },
  209. children: [
  210. {
  211. path: 'job-log',
  212. component: () => import('@/views/infra/job/logger/index.vue'),
  213. name: 'InfraJobLog',
  214. meta: {
  215. noCache: true,
  216. hidden: true,
  217. canTo: true,
  218. icon: 'ep:edit',
  219. title: '调度日志',
  220. activeMenu: 'infra/job/index'
  221. }
  222. }
  223. ]
  224. },
  225. {
  226. path: '/login',
  227. component: () => import('@/views/Login/Login.vue'),
  228. name: 'Login',
  229. meta: {
  230. hidden: true,
  231. title: t('router.login'),
  232. noTagsView: true
  233. }
  234. },
  235. {
  236. path: '/sso',
  237. component: () => import('@/views/Login/Login.vue'),
  238. name: 'SSOLogin',
  239. meta: {
  240. hidden: true,
  241. title: t('router.login'),
  242. noTagsView: true
  243. }
  244. },
  245. {
  246. path: '/social-login',
  247. component: () => import('@/views/Login/SocialLogin.vue'),
  248. name: 'SocialLogin',
  249. meta: {
  250. hidden: true,
  251. title: t('router.socialLogin'),
  252. noTagsView: true
  253. }
  254. },
  255. {
  256. path: '/403',
  257. component: () => import('@/views/Error/403.vue'),
  258. name: 'NoAccess',
  259. meta: {
  260. hidden: true,
  261. title: '403',
  262. noTagsView: true
  263. }
  264. },
  265. {
  266. path: '/404',
  267. component: () => import('@/views/Error/404.vue'),
  268. name: 'NoFound',
  269. meta: {
  270. hidden: true,
  271. title: '404',
  272. noTagsView: true
  273. }
  274. },
  275. {
  276. path: '/500',
  277. component: () => import('@/views/Error/500.vue'),
  278. name: 'Error',
  279. meta: {
  280. hidden: true,
  281. title: '500',
  282. noTagsView: true
  283. }
  284. },
  285. {
  286. path: '/supplier/product', // 商品中心
  287. component: Layout,
  288. name: 'SupplierCenter',
  289. meta: {
  290. hidden: true
  291. },
  292. children: [
  293. {
  294. path: 'supplier/detail/add',
  295. component: () => import('@/views/supplier/base/form/index.vue'),
  296. name: 'SupplierDetailAdd',
  297. meta: {
  298. noCache: false,
  299. hidden: true,
  300. canTo: true,
  301. icon: 'ep:edit',
  302. title: '供应商添加',
  303. activeMenu: '/supplier/base'
  304. }
  305. },
  306. {
  307. path: 'supplier/detail/edit/:id(\\d+)',
  308. component: () => import('@/views/supplier/base/form/index.vue'),
  309. name: 'SupplierDetailEdit',
  310. meta: {
  311. noCache: true,
  312. hidden: true,
  313. canTo: true,
  314. icon: 'ep:edit',
  315. title: '供应商编辑',
  316. activeMenu: '/supplier/base'
  317. }
  318. },
  319. {
  320. path: '/supplier/detail/info/:id(\\d+)',
  321. component: () => import('@/views/supplier/base/form/index.vue'),
  322. name: 'SupplierDetailInfo',
  323. meta: {
  324. noCache: true,
  325. hidden: true,
  326. canTo: true,
  327. icon: 'ep:view',
  328. title: '供应商详情',
  329. activeMenu: '/supplier/base'
  330. }
  331. },
  332. {
  333. path: 'supplier/approvalDetail/:id',
  334. name: 'SupplierApprovalInfo',
  335. meta: {
  336. title: '供应商审核详情',
  337. noCache: true,
  338. hidden: true,
  339. activeMenu: '/supplier/base'
  340. },
  341. component: () => import('@/views/supplier/approvaldetail/ApprovalDetail.vue')
  342. }
  343. ]
  344. },
  345. {
  346. path: '/bpm',
  347. component: Layout,
  348. name: 'bpm',
  349. meta: {
  350. hidden: true
  351. },
  352. children: [
  353. {
  354. path: 'manager/form/edit',
  355. component: () => import('@/views/bpm/form/editor/index.vue'),
  356. name: 'BpmFormEditor',
  357. meta: {
  358. noCache: true,
  359. hidden: true,
  360. canTo: true,
  361. title: '设计流程表单',
  362. activeMenu: '/bpm/manager/form'
  363. }
  364. },
  365. {
  366. path: 'manager/definition',
  367. component: () => import('@/views/bpm/model/definition/index.vue'),
  368. name: 'BpmProcessDefinition',
  369. meta: {
  370. noCache: true,
  371. hidden: true,
  372. canTo: true,
  373. title: '流程定义',
  374. activeMenu: '/bpm/manager/model'
  375. }
  376. },
  377. {
  378. path: 'process-instance/detail',
  379. component: () => import('@/views/bpm/processInstance/detail/index.vue'),
  380. name: 'BpmProcessInstanceDetail',
  381. meta: {
  382. noCache: true,
  383. hidden: true,
  384. canTo: true,
  385. title: '流程详情',
  386. activeMenu: '/bpm/task/my'
  387. },
  388. props: (route) => ({
  389. id: route.query.id,
  390. taskId: route.query.taskId,
  391. activityId: route.query.activityId
  392. })
  393. },
  394. {
  395. path: 'process-instance/report',
  396. component: () => import('@/views/bpm/processInstance/report/index.vue'),
  397. name: 'BpmProcessInstanceReport',
  398. meta: {
  399. noCache: true,
  400. hidden: true,
  401. canTo: true,
  402. title: '数据报表',
  403. activeMenu: '/bpm/manager/model'
  404. }
  405. },
  406. {
  407. path: 'oa/leave/create',
  408. component: () => import('@/views/bpm/oa/leave/create.vue'),
  409. name: 'OALeaveCreate',
  410. meta: {
  411. noCache: true,
  412. hidden: true,
  413. canTo: true,
  414. title: '发起 OA 请假',
  415. activeMenu: '/bpm/oa/leave'
  416. }
  417. },
  418. {
  419. path: 'oa/leave/detail',
  420. component: () => import('@/views/bpm/oa/leave/detail.vue'),
  421. name: 'OALeaveDetail',
  422. meta: {
  423. noCache: true,
  424. hidden: true,
  425. canTo: true,
  426. title: '查看 OA 请假',
  427. activeMenu: '/bpm/oa/leave'
  428. }
  429. },
  430. {
  431. path: 'manager/model/create',
  432. component: () => import('@/views/bpm/model/form/index.vue'),
  433. name: 'BpmModelCreate',
  434. meta: {
  435. noCache: true,
  436. hidden: true,
  437. canTo: true,
  438. title: '创建流程',
  439. activeMenu: '/bpm/manager/model'
  440. }
  441. },
  442. {
  443. path: 'manager/model/:type/:id',
  444. component: () => import('@/views/bpm/model/form/index.vue'),
  445. name: 'BpmModelUpdate',
  446. meta: {
  447. noCache: true,
  448. hidden: true,
  449. canTo: true,
  450. title: '修改流程',
  451. activeMenu: '/bpm/manager/model'
  452. }
  453. }
  454. ]
  455. },
  456. {
  457. path: '/mall/product', // 商品中心
  458. component: Layout,
  459. name: 'ProductCenter',
  460. meta: {
  461. hidden: true
  462. },
  463. children: [
  464. {
  465. path: 'spu/add',
  466. component: () => import('@/views/mall/product/spu/form/index.vue'),
  467. name: 'ProductSpuAdd',
  468. meta: {
  469. noCache: false, // 需要缓存
  470. hidden: true,
  471. canTo: true,
  472. icon: 'ep:edit',
  473. title: '商品添加',
  474. activeMenu: '/mall/product/spu'
  475. }
  476. },
  477. {
  478. path: 'spu/edit/:id(\\d+)',
  479. component: () => import('@/views/mall/product/spu/form/index.vue'),
  480. name: 'ProductSpuEdit',
  481. meta: {
  482. noCache: true,
  483. hidden: true,
  484. canTo: true,
  485. icon: 'ep:edit',
  486. title: '商品编辑',
  487. activeMenu: '/mall/product/spu'
  488. }
  489. },
  490. {
  491. path: 'spu/detail/:id(\\d+)',
  492. component: () => import('@/views/mall/product/spu/form/index.vue'),
  493. name: 'ProductSpuDetail',
  494. meta: {
  495. noCache: true,
  496. hidden: true,
  497. canTo: true,
  498. icon: 'ep:view',
  499. title: '商品详情',
  500. activeMenu: '/mall/product/spu'
  501. }
  502. },
  503. {
  504. path: 'property/value/:propertyId(\\d+)',
  505. component: () => import('@/views/mall/product/property/value/index.vue'),
  506. name: 'ProductPropertyValue',
  507. meta: {
  508. noCache: true,
  509. hidden: true,
  510. canTo: true,
  511. icon: 'ep:view',
  512. title: '商品属性值',
  513. activeMenu: '/product/property'
  514. }
  515. }
  516. ]
  517. },
  518. {
  519. path: '/mall/trade', // 交易中心
  520. component: Layout,
  521. name: 'TradeCenter',
  522. meta: {
  523. hidden: true
  524. },
  525. children: [
  526. {
  527. path: 'order/detail/:id(\\d+)',
  528. component: () => import('@/views/mall/trade/order/detail/index.vue'),
  529. name: 'TradeOrderDetail',
  530. meta: { title: '订单详情', icon: 'ep:view', activeMenu: '/mall/trade/order' }
  531. },
  532. {
  533. path: 'after-sale/detail/:id(\\d+)',
  534. component: () => import('@/views/mall/trade/afterSale/detail/index.vue'),
  535. name: 'TradeAfterSaleDetail',
  536. meta: { title: '退款详情', icon: 'ep:view', activeMenu: '/mall/trade/after-sale' }
  537. }
  538. ]
  539. },
  540. {
  541. path: '/member',
  542. component: Layout,
  543. name: 'MemberCenter',
  544. meta: { hidden: true },
  545. children: [
  546. {
  547. path: 'user/detail/:id',
  548. name: 'MemberUserDetail',
  549. meta: {
  550. title: '会员详情',
  551. noCache: true,
  552. hidden: true
  553. },
  554. component: () => import('@/views/member/user/detail/index.vue')
  555. }
  556. ]
  557. },
  558. {
  559. path: '/pay',
  560. component: Layout,
  561. name: 'pay',
  562. meta: { hidden: true },
  563. children: [
  564. {
  565. path: 'cashier',
  566. name: 'PayCashier',
  567. meta: {
  568. title: '收银台',
  569. noCache: true,
  570. hidden: true
  571. },
  572. component: () => import('@/views/pay/cashier/index.vue')
  573. }
  574. ]
  575. },
  576. {
  577. path: '/diy',
  578. name: 'DiyCenter',
  579. meta: { hidden: true },
  580. component: Layout,
  581. children: [
  582. {
  583. path: 'template/decorate/:id',
  584. name: 'DiyTemplateDecorate',
  585. meta: {
  586. title: '模板装修',
  587. noCache: true,
  588. hidden: true,
  589. activeMenu: '/mall/promotion/diy/template'
  590. },
  591. component: () => import('@/views/mall/promotion/diy/template/decorate.vue')
  592. },
  593. {
  594. path: 'page/decorate/:id',
  595. name: 'DiyPageDecorate',
  596. meta: {
  597. title: '页面装修',
  598. noCache: true,
  599. hidden: true,
  600. activeMenu: '/mall/promotion/diy/page'
  601. },
  602. component: () => import('@/views/mall/promotion/diy/page/decorate.vue')
  603. }
  604. ]
  605. },
  606. {
  607. path: '/crm',
  608. component: Layout,
  609. name: 'CrmCenter',
  610. meta: { hidden: true },
  611. children: [
  612. {
  613. path: 'clue/detail/:id',
  614. name: 'CrmClueDetail',
  615. meta: {
  616. title: '线索详情',
  617. noCache: true,
  618. hidden: true,
  619. activeMenu: '/crm/clue'
  620. },
  621. component: () => import('@/views/crm/clue/detail/index.vue')
  622. },
  623. {
  624. path: 'customer/detail/:id',
  625. name: 'CrmCustomerDetail',
  626. meta: {
  627. title: '客户详情',
  628. noCache: true,
  629. hidden: true,
  630. activeMenu: '/crm/customer'
  631. },
  632. component: () => import('@/views/crm/customer/detail/index.vue')
  633. },
  634. {
  635. path: 'business/detail/:id',
  636. name: 'CrmBusinessDetail',
  637. meta: {
  638. title: '商机详情',
  639. noCache: true,
  640. hidden: true,
  641. activeMenu: '/crm/business'
  642. },
  643. component: () => import('@/views/crm/business/detail/index.vue')
  644. },
  645. {
  646. path: 'contract/detail/:id',
  647. name: 'CrmContractDetail',
  648. meta: {
  649. title: '合同详情',
  650. noCache: true,
  651. hidden: true,
  652. activeMenu: '/crm/contract'
  653. },
  654. component: () => import('@/views/crm/contract/detail/index.vue')
  655. },
  656. {
  657. path: 'receivable-plan/detail/:id',
  658. name: 'CrmReceivablePlanDetail',
  659. meta: {
  660. title: '回款计划详情',
  661. noCache: true,
  662. hidden: true,
  663. activeMenu: '/crm/receivable-plan'
  664. },
  665. component: () => import('@/views/crm/receivable/plan/detail/index.vue')
  666. },
  667. {
  668. path: 'receivable/detail/:id',
  669. name: 'CrmReceivableDetail',
  670. meta: {
  671. title: '回款详情',
  672. noCache: true,
  673. hidden: true,
  674. activeMenu: '/crm/receivable'
  675. },
  676. component: () => import('@/views/crm/receivable/detail/index.vue')
  677. },
  678. {
  679. path: 'contact/detail/:id',
  680. name: 'CrmContactDetail',
  681. meta: {
  682. title: '联系人详情',
  683. noCache: true,
  684. hidden: true,
  685. activeMenu: '/crm/contact'
  686. },
  687. component: () => import('@/views/crm/contact/detail/index.vue')
  688. },
  689. {
  690. path: 'product/detail/:id',
  691. name: 'CrmProductDetail',
  692. meta: {
  693. title: '产品详情',
  694. noCache: true,
  695. hidden: true,
  696. activeMenu: '/crm/product'
  697. },
  698. component: () => import('@/views/crm/product/detail/index.vue')
  699. }
  700. ]
  701. },
  702. {
  703. path: '/ai',
  704. component: Layout,
  705. name: 'Ai',
  706. meta: {
  707. hidden: true
  708. },
  709. children: [
  710. {
  711. path: 'image/square',
  712. component: () => import('@/views/ai/image/square/index.vue'),
  713. name: 'AiImageSquare',
  714. meta: {
  715. title: '绘图作品',
  716. icon: 'ep:home-filled',
  717. noCache: false
  718. }
  719. },
  720. {
  721. path: 'knowledge/document',
  722. component: () => import('@/views/ai/knowledge/document/index.vue'),
  723. name: 'AiKnowledgeDocument',
  724. meta: {
  725. title: '知识库文档',
  726. icon: 'ep:document',
  727. noCache: false,
  728. activeMenu: '/ai/knowledge'
  729. }
  730. },
  731. {
  732. path: 'knowledge/document/create',
  733. component: () => import('@/views/ai/knowledge/document/form/index.vue'),
  734. name: 'AiKnowledgeDocumentCreate',
  735. meta: {
  736. title: '创建文档',
  737. icon: 'ep:plus',
  738. noCache: true,
  739. hidden: true,
  740. activeMenu: '/ai/knowledge'
  741. }
  742. },
  743. {
  744. path: 'knowledge/document/update',
  745. component: () => import('@/views/ai/knowledge/document/form/index.vue'),
  746. name: 'AiKnowledgeDocumentUpdate',
  747. meta: {
  748. title: '修改文档',
  749. icon: 'ep:edit',
  750. noCache: true,
  751. hidden: true,
  752. activeMenu: '/ai/knowledge'
  753. }
  754. },
  755. {
  756. path: 'knowledge/retrieval',
  757. component: () => import('@/views/ai/knowledge/knowledge/retrieval/index.vue'),
  758. name: 'AiKnowledgeRetrieval',
  759. meta: {
  760. title: '文档召回测试',
  761. icon: 'ep:search',
  762. noCache: true,
  763. hidden: true,
  764. activeMenu: '/ai/knowledge'
  765. }
  766. },
  767. {
  768. path: 'knowledge/segment',
  769. component: () => import('@/views/ai/knowledge/segment/index.vue'),
  770. name: 'AiKnowledgeSegment',
  771. meta: {
  772. title: '知识库分段',
  773. icon: 'ep:tickets',
  774. noCache: true,
  775. hidden: true,
  776. activeMenu: '/ai/knowledge'
  777. }
  778. },
  779. // TODO @lesan::type =》 design 设计 AI 工作流
  780. {
  781. path: 'console/workflow/:type/:id',
  782. component: () => import('@/views/ai/workflow/manager/WorkflowModelForm.vue'),
  783. name: 'AiWorkflowUpdate',
  784. meta: {
  785. noCache: true,
  786. hidden: true,
  787. canTo: true,
  788. title: '修改 AI 工作流',
  789. activeMenu: '/ai/console/workflow'
  790. }
  791. }
  792. ]
  793. },
  794. {
  795. path: '/:pathMatch(.*)*',
  796. component: () => import('@/views/Error/404.vue'),
  797. name: '',
  798. meta: {
  799. title: '404',
  800. hidden: true,
  801. breadcrumb: false
  802. }
  803. },
  804. {
  805. path: '/iot',
  806. component: Layout,
  807. name: 'IOT',
  808. meta: {
  809. hidden: true
  810. },
  811. children: [
  812. {
  813. path: 'product/product/detail/:id',
  814. name: 'IoTProductDetail',
  815. meta: {
  816. title: '产品详情',
  817. noCache: true,
  818. hidden: true,
  819. activeMenu: '/iot/device/product'
  820. },
  821. component: () => import('@/views/iot/product/product/detail/index.vue')
  822. },
  823. {
  824. path: 'device/detail/:id',
  825. name: 'IoTDeviceDetail',
  826. meta: {
  827. title: '设备详情',
  828. noCache: true,
  829. hidden: true,
  830. activeMenu: '/iot/device/device'
  831. },
  832. component: () => import('@/views/iot/device/device/detail/index.vue')
  833. },
  834. {
  835. path: 'plugin/detail/:id',
  836. name: 'IoTPluginDetail',
  837. meta: {
  838. title: '插件详情',
  839. noCache: true,
  840. hidden: true,
  841. activeMenu: '/iot/plugin'
  842. },
  843. component: () => import('@/views/iot/plugin/detail/index.vue')
  844. }
  845. ]
  846. }
  847. ]
  848. export default remainingRouter