remaining.ts 33 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265126612671268126912701271127212731274127512761277127812791280128112821283128412851286
  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: '/user',
  64. component: Layout,
  65. name: 'UserInfo',
  66. meta: {
  67. hidden: true
  68. },
  69. children: [
  70. {
  71. path: 'profile',
  72. component: () => import('@/views/Profile/Index.vue'),
  73. name: 'Profile',
  74. meta: {
  75. canTo: true,
  76. hidden: true,
  77. noTagsView: false,
  78. icon: 'ep:user',
  79. title: t('common.profile')
  80. }
  81. },
  82. {
  83. path: 'notify-message',
  84. component: () => import('@/views/system/notify/my/index.vue'),
  85. name: 'MyNotifyMessage',
  86. meta: {
  87. canTo: true,
  88. hidden: true,
  89. noTagsView: false,
  90. icon: 'ep:message',
  91. title: '我的站内信'
  92. }
  93. },
  94. {
  95. path: 'notify-agent',
  96. component: () => import('@/views/system/notify/agent/index.vue'),
  97. name: 'Agent',
  98. meta: {
  99. canTo: true,
  100. hidden: true,
  101. noTagsView: false,
  102. icon: 'ep:message',
  103. title: '我的代办'
  104. }
  105. }
  106. ]
  107. },
  108. {
  109. path: '/rolePage',
  110. component: Layout,
  111. name: 'rolePage',
  112. meta: {
  113. hidden: true,
  114. },
  115. children: [
  116. {
  117. path: 'RP/create',
  118. component: () => import('@/views/system/rolePage/createForm.vue'),
  119. name: 'createForm',
  120. meta: {
  121. title: '角色操作页面',
  122. noCache: false,
  123. hidden: true,
  124. canTo: true,
  125. icon: 'ep:view',
  126. activeMenu: '/rolePage/RP/createForm'
  127. }
  128. },
  129. // {
  130. // path: 'RP/update',
  131. // component: () => import('@/views/system/rolePage/updateForm.vue'),
  132. // name: 'updateForm',
  133. // meta: {
  134. // title: '角色页面修改',
  135. // noCache: false,
  136. // hidden: true,
  137. // canTo: true,
  138. // icon: 'ep:view',
  139. // activeMenu: '/rolePage/RP/updateForm'
  140. // }
  141. // },
  142. ]
  143. },
  144. {
  145. path: '/CustomWorkflow',
  146. component: Layout,
  147. name: 'CustomWorkflow',
  148. meta: {
  149. hidden: true,
  150. },
  151. children: [
  152. {
  153. path: 'CW/create',
  154. component: () => import('@/views/CustomWorkflow/CW/CreateView.vue'),
  155. name: 'CreateView',
  156. meta: {
  157. title: '自定义作业流程新增',
  158. noCache: false,
  159. hidden: true,
  160. canTo: true,
  161. icon: 'ep:view',
  162. activeMenu: '/CustomWorkflow/CW/CreateView'
  163. }
  164. },
  165. {
  166. path: 'CW/update',
  167. component: () => import('@/views/CustomWorkflow/CW/UpdateView.vue'),
  168. name: 'UpdateView',
  169. meta: {
  170. title: '自定义作业流程修改',
  171. noCache: true,
  172. hidden: true,
  173. canTo: true,
  174. icon: 'ep:view',
  175. activeMenu: '/CustomWorkflow/CW/UpdateView'
  176. }
  177. },
  178. {
  179. path: 'CW/view',
  180. component: () => import('@/views/CustomWorkflow/CW/CheckView.vue'),
  181. name: 'CheckView',
  182. meta: {
  183. title: '自定义作业流程查看',
  184. noCache: true,
  185. hidden: true,
  186. canTo: true,
  187. icon: 'ep:view',
  188. activeMenu: '/CustomWorkflow/CW/CheckView'
  189. },
  190. },
  191. {
  192. path: 'CW/TableStepDetail',
  193. component: () => import('@/views/CustomWorkflow/CW/TableStepDetail.vue'),
  194. name: 'WorkflowTableStepDetail',
  195. meta: {
  196. title: '步骤操作说明',
  197. noCache: true,
  198. hidden: true,
  199. canTo: true,
  200. icon: 'ep:view',
  201. activeMenu: '/CustomWorkflow/CW/TableStepDetail'
  202. }
  203. },
  204. ]
  205. },
  206. {
  207. path: '/CustomStepTemplate',
  208. component: Layout,
  209. name: 'CustomStepTemplate',
  210. meta: {
  211. hidden: true,
  212. },
  213. children: [
  214. {
  215. path: 'CustomStepTemplate/CS/StepTemplateDetail',
  216. component: () => import('@/views/CustomStepTemplate/CS/StepTemplateDetail.vue'),
  217. name: 'StepTemplateDetail',
  218. meta: {
  219. title: '步骤操作说明',
  220. noCache: true,
  221. hidden: true,
  222. canTo: true,
  223. icon: 'ep:view',
  224. activeMenu: '/CustomStepTemplate/CS/StepTemplateDetail'
  225. }
  226. },
  227. ]
  228. },
  229. {
  230. path: '/sopm',
  231. component: Layout,
  232. name: 'sopm',
  233. meta: {
  234. hidden: true,
  235. },
  236. children: [
  237. {
  238. path: 'sopm/sop/CreateSop',
  239. component: () => import('@/views/sopm/sop/CreateSop.vue'),
  240. name: 'CreateSop',
  241. meta: {
  242. title: 'sop新增',
  243. noCache: true,
  244. noTagsView: true,
  245. hidden: true,
  246. canTo: true,
  247. icon: 'ep:view',
  248. activeMenu: '/sopm/sop'
  249. }
  250. },
  251. {
  252. path: 'sopm/sop/UpdateSop',
  253. component: () => import('@/views/sopm/sop/UpdateSop.vue'),
  254. name: 'UpdateSop',
  255. meta: {
  256. title: 'sop修改',
  257. noTagsView: true,
  258. noCache: true,
  259. hidden: true,
  260. canTo: true,
  261. icon: 'ep:view',
  262. activeMenu: '/sopm/sop'
  263. }
  264. },
  265. {
  266. path: 'sopm/sop/SetModeStep',
  267. component: () => import('@/views/sopm/sop/SetModeStep.vue'),
  268. name: 'SetModeStep',
  269. meta: {
  270. title: '设置模式步骤',
  271. noCache: true,
  272. noTagsView: true,
  273. hidden: true,
  274. canTo: true,
  275. icon: 'ep:view',
  276. activeMenu: '/sopm/sop/SetModeStep'
  277. }
  278. },
  279. {
  280. path: 'sopm/sop/SetPoint',
  281. component: () => import('@/views/sopm/sop/SetPoint.vue'),
  282. name: 'SetPoint',
  283. meta: {
  284. title: '设置点位',
  285. noCache: true,
  286. noTagsView: true,
  287. hidden: true,
  288. canTo: true,
  289. icon: 'ep:view',
  290. activeMenu: '/sopm/sop/SetPoint'
  291. }
  292. },
  293. {
  294. path: 'sopm/sop/SetUser',
  295. component: () => import('@/views/sopm/sop/SetUser.vue'),
  296. name: 'SetUser',
  297. meta: {
  298. title: '设置人员',
  299. noCache: true,
  300. noTagsView: true,
  301. hidden: true,
  302. canTo: true,
  303. icon: 'ep:view',
  304. activeMenu: '/sopm/sop/SetUser'
  305. }
  306. },
  307. {
  308. path: 'sopm/sop/ModeView/TableStepDetail',
  309. component: () => import('@/views/sopm/sop/ModeView/TableStepDetail.vue'),
  310. name: 'TableStepDetail',
  311. meta: {
  312. title: '步骤操作说明',
  313. noCache: true,
  314. hidden: true,
  315. canTo: true,
  316. icon: 'ep:view',
  317. activeMenu: '/sopm/sop/ModeView/TableStepDetail'
  318. }
  319. },
  320. {
  321. path: 'sopm/sop/ExecutePlan',
  322. component: () => import('@/views/sopm/sop/ExecutePlan.vue'),
  323. name: 'ExecutePlan',
  324. meta: {
  325. title: 'sop执行计划',
  326. noCache: true,
  327. noTagsView: true,
  328. hidden: true,
  329. canTo: true,
  330. icon: 'ep:view',
  331. activeMenu: '/sopm/sop'
  332. }
  333. },
  334. {
  335. path: 'sopm/sop/NotificationRules',
  336. component: () => import('@/views/sopm/sop/NotificationRules.vue'),
  337. name: 'NotificationRules',
  338. meta: {
  339. title: 'sop通知规则',
  340. noCache: true,
  341. noTagsView: true,
  342. hidden: true,
  343. canTo: true,
  344. icon: 'ep:view',
  345. activeMenu: '/sopm/sop'
  346. }
  347. },
  348. {
  349. path: 'sopm/sop/NotificationUpdate',
  350. component: () => import('@/views/sopm/sop/NotificationUpdate.vue'),
  351. name: 'NotificationUpdate',
  352. meta: {
  353. title: 'sop通知规则新增修改',
  354. noCache: true,
  355. noTagsView: true,
  356. hidden: true,
  357. canTo: true,
  358. icon: 'ep:view',
  359. activeMenu: '/sopm/sop'
  360. }
  361. },
  362. {
  363. path: 'sopm/sop/HistoricalSopJob',
  364. component: () => import('@/views/sopm/sop/HistoricalSopJob.vue'),
  365. name: 'HistoricalSopJob',
  366. meta: {
  367. title: 'sop历史作业',
  368. noCache: true,
  369. noTagsView: true,
  370. hidden: true,
  371. canTo: true,
  372. icon: 'ep:view',
  373. activeMenu: '/sopm/sop'
  374. }
  375. },
  376. ]
  377. },
  378. {
  379. path: '/jobTicket',
  380. component: Layout,
  381. name: 'jobTicket',
  382. meta: {
  383. hidden: true,
  384. },
  385. children: [
  386. {
  387. path: 'jobTicket/job/CreateJob',
  388. component: () => import('@/views/jobTicket/job/CreateJob.vue'),
  389. name: 'CreateJob',
  390. meta: {
  391. title: '作业票新增',
  392. noCache: true,
  393. noTagsView: true,
  394. hidden: true,
  395. canTo: true,
  396. icon: 'ep:view',
  397. activeMenu: '/jobTicket/job'
  398. }
  399. },
  400. {
  401. path: 'jobTicket/job/CreateSopJob',
  402. component: () => import('@/views/jobTicket/job/CreateSopJob.vue'),
  403. name: 'CreateSopJob',
  404. meta: {
  405. title: '作业票新增',
  406. noCache: true,
  407. noTagsView: true,
  408. hidden: true,
  409. canTo: true,
  410. icon: 'ep:view',
  411. activeMenu: '/jobTicket/job'
  412. }
  413. },
  414. {
  415. path: 'jobTicket/job/UpdateJob',
  416. component: () => import('@/views/jobTicket/job/UpdateJob.vue'),
  417. name: 'UpdateJob',
  418. meta: {
  419. title: '作业票修改',
  420. noTagsView: true,
  421. noCache: true,
  422. hidden: true,
  423. canTo: true,
  424. icon: 'ep:view',
  425. activeMenu: '/jobTicket/job'
  426. }
  427. },
  428. {
  429. path: 'jobTicket/job/SetModeStep',
  430. component: () => import('@/views/jobTicket/job/SetModeStep.vue'),
  431. name: 'SetJobModeStep',
  432. meta: {
  433. title: '设置模式步骤',
  434. noCache: true,
  435. noTagsView: true,
  436. hidden: true,
  437. canTo: true,
  438. icon: 'ep:view',
  439. activeMenu: '/jobTicket/job/SetModeStep'
  440. }
  441. },
  442. {
  443. path: 'jobTicket/job/SetPoint',
  444. component: () => import('@/views/jobTicket/job/SetPoint.vue'),
  445. name: 'SetJobPoint',
  446. meta: {
  447. title: '设置点位',
  448. noCache: true,
  449. noTagsView: true,
  450. hidden: true,
  451. canTo: true,
  452. icon: 'ep:view',
  453. activeMenu: '/jobTicket/job/SetPoint'
  454. }
  455. },
  456. {
  457. path: 'jobTicket/job/SetUser',
  458. component: () => import('@/views/jobTicket/job/SetUser.vue'),
  459. name: 'SetJobUser',
  460. meta: {
  461. title: '设置人员',
  462. noCache: true,
  463. noTagsView: true,
  464. hidden: true,
  465. canTo: true,
  466. icon: 'ep:view',
  467. activeMenu: '/jobTicket/job/SetUser'
  468. }
  469. },
  470. {
  471. path: 'jobTicket/job/ModeView/TableStepDetail',
  472. component: () => import('@/views/jobTicket/job/ModeView/TableStepDetail.vue'),
  473. name: 'jobTableStepDetail',
  474. meta: {
  475. title: '步骤操作说明',
  476. noCache: true,
  477. hidden: true,
  478. canTo: true,
  479. icon: 'ep:view',
  480. activeMenu: '/jobTicket/job/ModeView/TableStepDetail'
  481. }
  482. },
  483. {
  484. path: 'jobTicket/job/JobMonitor',
  485. component: () => import('@/views/jobTicket/job/JobMonitor.vue'),
  486. name: 'JobMonitor',
  487. meta: {
  488. title:'作业执行监控',
  489. noTagsView: true,
  490. noCache: true,
  491. hidden: true,
  492. canTo: true,
  493. icon: 'ep:view',
  494. activeMenu: '/jobTicket/job'
  495. }
  496. },
  497. ]
  498. },
  499. {
  500. path: '/material',
  501. component: Layout,
  502. name: 'Material',
  503. meta: {
  504. hidden: true
  505. },
  506. children: [
  507. {
  508. path: 'standard/propertyValue',
  509. component: () => import('@/views/material/standard/propertyValue.vue'),
  510. name: 'propertyValue',
  511. meta: {
  512. title: '规格设置',
  513. noCache: true,
  514. hidden: true,
  515. canTo: true,
  516. icon: 'ep:view',
  517. activeMenu: '/material/standard/propertyValue'
  518. }
  519. },
  520. {
  521. path: 'instructions/instructionsDetail',
  522. component: () => import('@/views/material/instructions/instructionsDetail.vue'),
  523. name: 'instructionsDetail',
  524. meta: {
  525. title: '使用说明详情',
  526. noCache: true,
  527. hidden: true,
  528. canTo: true,
  529. icon: 'ep:view',
  530. activeMenu: '/material/instructions/instructionsDetail'
  531. }
  532. },
  533. {
  534. path: 'lockers/DetailsIndex',
  535. component: () => import('@/views/material/lockers/DetailsIndex.vue'),
  536. name: 'DetailsIndex',
  537. meta: {
  538. title: '',
  539. noCache: true,
  540. hidden: true,
  541. canTo: true,
  542. icon: 'ep:view',
  543. activeMenu: '/material/lockers/DetailsIndex',
  544. },
  545. beforeEnter: (to, from, next) => {
  546. // 动态设置菜单标题
  547. to.meta.title = to.query.cabinetName || '默认标题';
  548. next();
  549. }
  550. }
  551. ]
  552. },
  553. {
  554. path: '/dv',
  555. component: Layout,
  556. name: 'Dv',
  557. meta: {
  558. hidden: true
  559. },
  560. children: [
  561. {
  562. path: 'technology/technologyDetail/CraftDetail',
  563. component: () => import('@/views/dv/technology/technologyDetail/CraftDetail.vue'),
  564. name: 'TechnologyCraftDetail',
  565. meta: {
  566. title: '工艺详情',
  567. noCache: true,
  568. hidden: true,
  569. canTo: true,
  570. icon: 'ep:view',
  571. activeMenu: '/dv/technology/technologyDetail/CraftDetail'
  572. }
  573. },
  574. {
  575. path: 'technology/technologyDetail/DeviceDetail',
  576. component: () => import('@/views/dv/technology/technologyDetail/DeviceDetail.vue'),
  577. name: 'TechnologyDeviceDetail',
  578. meta: {
  579. title: '设备详情',
  580. noCache: true,
  581. hidden: true,
  582. canTo: true,
  583. icon: 'ep:view',
  584. activeMenu: '/dv/technology/technologyDetail/DeviceDetail'
  585. }
  586. },
  587. {
  588. path: 'lotoStation/LookDetail',
  589. component: () => import('@/views/dv/lotoStation/LookDetail.vue'),
  590. name: 'lotoStationDetail',
  591. meta: {
  592. title: '锁定站详情',
  593. noCache: true,
  594. hidden: true,
  595. canTo: true,
  596. icon: 'ep:view',
  597. activeMenu: '/dv/lotoStation/LookDetail'
  598. }
  599. }
  600. ]
  601. },
  602. {
  603. path: '/hw',
  604. component: Layout,
  605. name: 'Hw',
  606. meta: {
  607. hidden: true
  608. },
  609. children: [
  610. {
  611. path: 'lockCabinet/lookDetail',
  612. component: () => import('@/views/hw/lockCabinet/lookDetail.vue'),
  613. name: 'HardwarelookDetail',
  614. meta: {
  615. title: '锁柜详情',
  616. noCache: true,
  617. hidden: true,
  618. canTo: true,
  619. icon: 'ep:view',
  620. activeMenu: '/hw/lockCabinet/lookDetail'
  621. }
  622. }
  623. ]
  624. },
  625. {
  626. path: '/dict',
  627. component: Layout,
  628. name: 'dict',
  629. meta: {
  630. hidden: true
  631. },
  632. children: [
  633. {
  634. path: 'type/data/:dictType',
  635. component: () => import('@/views/system/dict/data/index.vue'),
  636. name: 'SystemDictData',
  637. meta: {
  638. title: '字典数据',
  639. noCache: true,
  640. hidden: true,
  641. canTo: true,
  642. icon: '',
  643. activeMenu: '/system/dict'
  644. }
  645. }
  646. ]
  647. },
  648. {
  649. path: '/codegen',
  650. component: Layout,
  651. name: 'CodegenEdit',
  652. meta: {
  653. hidden: true
  654. },
  655. children: [
  656. {
  657. path: 'edit',
  658. component: () => import('@/views/infra/codegen/EditTable.vue'),
  659. name: 'InfraCodegenEditTable',
  660. meta: {
  661. noCache: true,
  662. hidden: true,
  663. canTo: true,
  664. icon: 'ep:edit',
  665. title: '修改生成配置',
  666. activeMenu: 'infra/codegen/index'
  667. }
  668. }
  669. ]
  670. },
  671. {
  672. path: '/job',
  673. component: Layout,
  674. name: 'JobL',
  675. meta: {
  676. hidden: true
  677. },
  678. children: [
  679. {
  680. path: 'job-log',
  681. component: () => import('@/views/infra/job/logger/index.vue'),
  682. name: 'InfraJobLog',
  683. meta: {
  684. noCache: true,
  685. hidden: true,
  686. canTo: true,
  687. icon: 'ep:edit',
  688. title: '调度日志',
  689. activeMenu: 'infra/job/index'
  690. }
  691. }
  692. ]
  693. },
  694. {
  695. path: '/login',
  696. component: () => import('@/views/Login/Login.vue'),
  697. name: 'Login',
  698. meta: {
  699. hidden: true,
  700. title: t('router.login'),
  701. noTagsView: true
  702. }
  703. },
  704. {
  705. path: '/sso',
  706. component: () => import('@/views/Login/Login.vue'),
  707. name: 'SSOLogin',
  708. meta: {
  709. hidden: true,
  710. title: t('router.login'),
  711. noTagsView: true
  712. }
  713. },
  714. {
  715. path: '/social-login',
  716. component: () => import('@/views/Login/SocialLogin.vue'),
  717. name: 'SocialLogin',
  718. meta: {
  719. hidden: true,
  720. title: t('router.socialLogin'),
  721. noTagsView: true
  722. }
  723. },
  724. {
  725. path: '/403',
  726. component: () => import('@/views/Error/403.vue'),
  727. name: 'NoAccess',
  728. meta: {
  729. hidden: true,
  730. title: '403',
  731. noTagsView: true
  732. }
  733. },
  734. {
  735. path: '/404',
  736. component: () => import('@/views/Error/404.vue'),
  737. name: 'NoFound',
  738. meta: {
  739. hidden: true,
  740. title: '404',
  741. noTagsView: true
  742. }
  743. },
  744. {
  745. path: '/500',
  746. component: () => import('@/views/Error/500.vue'),
  747. name: 'Error',
  748. meta: {
  749. hidden: true,
  750. title: '500',
  751. noTagsView: true
  752. }
  753. },
  754. {
  755. path: '/bpm',
  756. component: Layout,
  757. name: 'bpm',
  758. meta: {
  759. hidden: true
  760. },
  761. children: [
  762. {
  763. path: 'manager/form/edit',
  764. component: () => import('@/views/bpm/form/editor/index.vue'),
  765. name: 'BpmFormEditor',
  766. meta: {
  767. noCache: true,
  768. hidden: true,
  769. canTo: true,
  770. title: '设计流程表单',
  771. activeMenu: '/bpm/manager/form'
  772. }
  773. },
  774. {
  775. path: 'manager/definition',
  776. component: () => import('@/views/bpm/model/definition/index.vue'),
  777. name: 'BpmProcessDefinition',
  778. meta: {
  779. noCache: true,
  780. hidden: true,
  781. canTo: true,
  782. title: '流程定义',
  783. activeMenu: '/bpm/manager/model'
  784. }
  785. },
  786. {
  787. path: 'process-instance/detail',
  788. component: () => import('@/views/bpm/processInstance/detail/index.vue'),
  789. name: 'BpmProcessInstanceDetail',
  790. meta: {
  791. noCache: true,
  792. hidden: true,
  793. canTo: true,
  794. title: '流程详情',
  795. activeMenu: '/bpm/task/my'
  796. },
  797. props: (route) => ({
  798. id: route.query.id,
  799. taskId: route.query.taskId,
  800. activityId: route.query.activityId
  801. })
  802. },
  803. {
  804. path: 'process-instance/report',
  805. component: () => import('@/views/bpm/processInstance/report/index.vue'),
  806. name: 'BpmProcessInstanceReport',
  807. meta: {
  808. noCache: true,
  809. hidden: true,
  810. canTo: true,
  811. title: '数据报表',
  812. activeMenu: '/bpm/manager/model'
  813. }
  814. },
  815. {
  816. path: 'oa/leave/create',
  817. component: () => import('@/views/bpm/oa/leave/create.vue'),
  818. name: 'OALeaveCreate',
  819. meta: {
  820. noCache: true,
  821. hidden: true,
  822. canTo: true,
  823. title: '发起 OA 请假',
  824. activeMenu: '/bpm/oa/leave'
  825. }
  826. },
  827. {
  828. path: 'oa/leave/detail',
  829. component: () => import('@/views/bpm/oa/leave/detail.vue'),
  830. name: 'OALeaveDetail',
  831. meta: {
  832. noCache: true,
  833. hidden: true,
  834. canTo: true,
  835. title: '查看 OA 请假',
  836. activeMenu: '/bpm/oa/leave'
  837. }
  838. },
  839. {
  840. path: 'manager/model/create',
  841. component: () => import('@/views/bpm/model/form/index.vue'),
  842. name: 'BpmModelCreate',
  843. meta: {
  844. noCache: true,
  845. hidden: true,
  846. canTo: true,
  847. title: '创建流程',
  848. activeMenu: '/bpm/manager/model'
  849. }
  850. },
  851. {
  852. path: 'manager/model/:type/:id',
  853. component: () => import('@/views/bpm/model/form/index.vue'),
  854. name: 'BpmModelUpdate',
  855. meta: {
  856. noCache: true,
  857. hidden: true,
  858. canTo: true,
  859. title: '修改流程',
  860. activeMenu: '/bpm/manager/model'
  861. }
  862. }
  863. ]
  864. },
  865. {
  866. path: '/mall/product', // 商品中心
  867. component: Layout,
  868. name: 'ProductCenter',
  869. meta: {
  870. hidden: true
  871. },
  872. children: [
  873. {
  874. path: 'spu/add',
  875. component: () => import('@/views/mall/product/spu/form/index.vue'),
  876. name: 'ProductSpuAdd',
  877. meta: {
  878. noCache: false, // 需要缓存
  879. hidden: true,
  880. canTo: true,
  881. icon: 'ep:edit',
  882. title: '商品添加',
  883. activeMenu: '/mall/product/spu'
  884. }
  885. },
  886. {
  887. path: 'spu/edit/:id(\\d+)',
  888. component: () => import('@/views/mall/product/spu/form/index.vue'),
  889. name: 'ProductSpuEdit',
  890. meta: {
  891. noCache: true,
  892. hidden: true,
  893. canTo: true,
  894. icon: 'ep:edit',
  895. title: '商品编辑',
  896. activeMenu: '/mall/product/spu'
  897. }
  898. },
  899. {
  900. path: 'spu/detail/:id(\\d+)',
  901. component: () => import('@/views/mall/product/spu/form/index.vue'),
  902. name: 'ProductSpuDetail',
  903. meta: {
  904. noCache: true,
  905. hidden: true,
  906. canTo: true,
  907. icon: 'ep:view',
  908. title: '商品详情',
  909. activeMenu: '/mall/product/spu'
  910. }
  911. },
  912. {
  913. path: 'property/value/:propertyId(\\d+)',
  914. component: () => import('@/views/mall/product/property/value/index.vue'),
  915. name: 'ProductPropertyValue',
  916. meta: {
  917. noCache: true,
  918. hidden: true,
  919. canTo: true,
  920. icon: 'ep:view',
  921. title: '商品属性值',
  922. activeMenu: '/product/property'
  923. }
  924. }
  925. ]
  926. },
  927. {
  928. path: '/mall/trade', // 交易中心
  929. component: Layout,
  930. name: 'TradeCenter',
  931. meta: {
  932. hidden: true
  933. },
  934. children: [
  935. {
  936. path: 'order/detail/:id(\\d+)',
  937. component: () => import('@/views/mall/trade/order/detail/index.vue'),
  938. name: 'TradeOrderDetail',
  939. meta: {title: '订单详情', icon: 'ep:view', activeMenu: '/mall/trade/order'}
  940. },
  941. {
  942. path: 'after-sale/detail/:id(\\d+)',
  943. component: () => import('@/views/mall/trade/afterSale/detail/index.vue'),
  944. name: 'TradeAfterSaleDetail',
  945. meta: {title: '退款详情', icon: 'ep:view', activeMenu: '/mall/trade/after-sale'}
  946. }
  947. ]
  948. },
  949. {
  950. path: '/member',
  951. component: Layout,
  952. name: 'MemberCenter',
  953. meta: {hidden: true},
  954. children: [
  955. {
  956. path: 'user/detail/:id',
  957. name: 'MemberUserDetail',
  958. meta: {
  959. title: '会员详情',
  960. noCache: true,
  961. hidden: true
  962. },
  963. component: () => import('@/views/member/user/detail/index.vue')
  964. }
  965. ]
  966. },
  967. {
  968. path: '/pay',
  969. component: Layout,
  970. name: 'pay',
  971. meta: {hidden: true},
  972. children: [
  973. {
  974. path: 'cashier',
  975. name: 'PayCashier',
  976. meta: {
  977. title: '收银台',
  978. noCache: true,
  979. hidden: true
  980. },
  981. component: () => import('@/views/pay/cashier/index.vue')
  982. }
  983. ]
  984. },
  985. {
  986. path: '/diy',
  987. name: 'DiyCenter',
  988. meta: {hidden: true},
  989. component: Layout,
  990. children: [
  991. {
  992. path: 'template/decorate/:id',
  993. name: 'DiyTemplateDecorate',
  994. meta: {
  995. title: '模板装修',
  996. noCache: false,
  997. hidden: true,
  998. activeMenu: '/mall/promotion/diy-template/diy-template'
  999. },
  1000. component: () => import('@/views/mall/promotion/diy/template/decorate.vue')
  1001. },
  1002. {
  1003. path: 'page/decorate/:id',
  1004. name: 'DiyPageDecorate',
  1005. meta: {
  1006. title: '页面装修',
  1007. noCache: false,
  1008. hidden: true,
  1009. activeMenu: '/mall/promotion/diy-template/diy-page'
  1010. },
  1011. component: () => import('@/views/mall/promotion/diy/page/decorate.vue')
  1012. }
  1013. ]
  1014. },
  1015. {
  1016. path: '/crm',
  1017. component: Layout,
  1018. name: 'CrmCenter',
  1019. meta: {hidden: true},
  1020. children: [
  1021. {
  1022. path: 'clue/detail/:id',
  1023. name: 'CrmClueDetail',
  1024. meta: {
  1025. title: '线索详情',
  1026. noCache: true,
  1027. hidden: true,
  1028. activeMenu: '/crm/clue'
  1029. },
  1030. component: () => import('@/views/crm/clue/detail/index.vue')
  1031. },
  1032. {
  1033. path: 'customer/detail/:id',
  1034. name: 'CrmCustomerDetail',
  1035. meta: {
  1036. title: '客户详情',
  1037. noCache: true,
  1038. hidden: true,
  1039. activeMenu: '/crm/customer'
  1040. },
  1041. component: () => import('@/views/crm/customer/detail/index.vue')
  1042. },
  1043. {
  1044. path: 'business/detail/:id',
  1045. name: 'CrmBusinessDetail',
  1046. meta: {
  1047. title: '商机详情',
  1048. noCache: true,
  1049. hidden: true,
  1050. activeMenu: '/crm/business'
  1051. },
  1052. component: () => import('@/views/crm/business/detail/index.vue')
  1053. },
  1054. {
  1055. path: 'contract/detail/:id',
  1056. name: 'CrmContractDetail',
  1057. meta: {
  1058. title: '合同详情',
  1059. noCache: true,
  1060. hidden: true,
  1061. activeMenu: '/crm/contract'
  1062. },
  1063. component: () => import('@/views/crm/contract/detail/index.vue')
  1064. },
  1065. {
  1066. path: 'receivable-plan/detail/:id',
  1067. name: 'CrmReceivablePlanDetail',
  1068. meta: {
  1069. title: '回款计划详情',
  1070. noCache: true,
  1071. hidden: true,
  1072. activeMenu: '/crm/receivable-plan'
  1073. },
  1074. component: () => import('@/views/crm/receivable/plan/detail/index.vue')
  1075. },
  1076. {
  1077. path: 'receivable/detail/:id',
  1078. name: 'CrmReceivableDetail',
  1079. meta: {
  1080. title: '回款详情',
  1081. noCache: true,
  1082. hidden: true,
  1083. activeMenu: '/crm/receivable'
  1084. },
  1085. component: () => import('@/views/crm/receivable/detail/index.vue')
  1086. },
  1087. {
  1088. path: 'contact/detail/:id',
  1089. name: 'CrmContactDetail',
  1090. meta: {
  1091. title: '联系人详情',
  1092. noCache: true,
  1093. hidden: true,
  1094. activeMenu: '/crm/contact'
  1095. },
  1096. component: () => import('@/views/crm/contact/detail/index.vue')
  1097. },
  1098. {
  1099. path: 'product/detail/:id',
  1100. name: 'CrmProductDetail',
  1101. meta: {
  1102. title: '产品详情',
  1103. noCache: true,
  1104. hidden: true,
  1105. activeMenu: '/crm/product'
  1106. },
  1107. component: () => import('@/views/crm/product/detail/index.vue')
  1108. }
  1109. ]
  1110. },
  1111. {
  1112. path: '/ai',
  1113. component: Layout,
  1114. name: 'Ai',
  1115. meta: {
  1116. hidden: true
  1117. },
  1118. children: [
  1119. {
  1120. path: 'image/square',
  1121. component: () => import('@/views/ai/image/square/index.vue'),
  1122. name: 'AiImageSquare',
  1123. meta: {
  1124. title: '绘图作品',
  1125. icon: 'ep:home-filled',
  1126. noCache: false
  1127. }
  1128. },
  1129. {
  1130. path: 'knowledge/document',
  1131. component: () => import('@/views/ai/knowledge/document/index.vue'),
  1132. name: 'AiKnowledgeDocument',
  1133. meta: {
  1134. title: '知识库文档',
  1135. icon: 'ep:document',
  1136. noCache: false,
  1137. activeMenu: '/ai/knowledge'
  1138. }
  1139. },
  1140. {
  1141. path: 'knowledge/document/create',
  1142. component: () => import('@/views/ai/knowledge/document/form/index.vue'),
  1143. name: 'AiKnowledgeDocumentCreate',
  1144. meta: {
  1145. title: '创建文档',
  1146. icon: 'ep:plus',
  1147. noCache: true,
  1148. hidden: true,
  1149. activeMenu: '/ai/knowledge'
  1150. }
  1151. },
  1152. {
  1153. path: 'knowledge/document/update',
  1154. component: () => import('@/views/ai/knowledge/document/form/index.vue'),
  1155. name: 'AiKnowledgeDocumentUpdate',
  1156. meta: {
  1157. title: '修改文档',
  1158. icon: 'ep:edit',
  1159. noCache: true,
  1160. hidden: true,
  1161. activeMenu: '/ai/knowledge'
  1162. }
  1163. },
  1164. {
  1165. path: 'knowledge/retrieval',
  1166. component: () => import('@/views/ai/knowledge/knowledge/retrieval/index.vue'),
  1167. name: 'AiKnowledgeRetrieval',
  1168. meta: {
  1169. title: '文档召回测试',
  1170. icon: 'ep:search',
  1171. noCache: true,
  1172. hidden: true,
  1173. activeMenu: '/ai/knowledge'
  1174. }
  1175. },
  1176. {
  1177. path: 'knowledge/segment',
  1178. component: () => import('@/views/ai/knowledge/segment/index.vue'),
  1179. name: 'AiKnowledgeSegment',
  1180. meta: {
  1181. title: '知识库分段',
  1182. icon: 'ep:tickets',
  1183. noCache: true,
  1184. hidden: true,
  1185. activeMenu: '/ai/knowledge'
  1186. }
  1187. },
  1188. {
  1189. path: 'console/workflow/create',
  1190. component: () => import('@/views/ai/workflow/form/index.vue'),
  1191. name: 'AiWorkflowCreate',
  1192. meta: {
  1193. noCache: true,
  1194. hidden: true,
  1195. canTo: true,
  1196. title: '设计 AI 工作流',
  1197. activeMenu: '/ai/console/workflow'
  1198. }
  1199. },
  1200. {
  1201. path: 'console/workflow/:type/:id',
  1202. component: () => import('@/views/ai/workflow/form/index.vue'),
  1203. name: 'AiWorkflowUpdate',
  1204. meta: {
  1205. noCache: true,
  1206. hidden: true,
  1207. canTo: true,
  1208. title: '设计 AI 工作流',
  1209. activeMenu: '/ai/console/workflow'
  1210. }
  1211. }
  1212. ]
  1213. },
  1214. {
  1215. path: '/:pathMatch(.*)*',
  1216. component: () => import('@/views/Error/404.vue'),
  1217. name: '',
  1218. meta: {
  1219. title: '404',
  1220. hidden: true,
  1221. breadcrumb: false
  1222. }
  1223. },
  1224. {
  1225. path: '/iot',
  1226. component: Layout,
  1227. name: 'IOT',
  1228. meta: {
  1229. hidden: true
  1230. },
  1231. children: [
  1232. {
  1233. path: 'product/product/detail/:id',
  1234. name: 'IoTProductDetail',
  1235. meta: {
  1236. title: '产品详情',
  1237. noCache: true,
  1238. hidden: true,
  1239. activeMenu: '/iot/device/product'
  1240. },
  1241. component: () => import('@/views/iot/product/product/detail/index.vue')
  1242. },
  1243. {
  1244. path: 'device/detail/:id',
  1245. name: 'IoTDeviceDetail',
  1246. meta: {
  1247. title: '设备详情',
  1248. noCache: true,
  1249. hidden: true,
  1250. activeMenu: '/iot/device/device'
  1251. },
  1252. component: () => import('@/views/iot/device/device/detail/index.vue')
  1253. },
  1254. {
  1255. path: 'plugin/detail/:id',
  1256. name: 'IoTPluginDetail',
  1257. meta: {
  1258. title: '插件详情',
  1259. noCache: true,
  1260. hidden: true,
  1261. activeMenu: '/iot/plugin'
  1262. },
  1263. component: () => import('@/views/iot/plugin/detail/index.vue')
  1264. }
  1265. ]
  1266. }
  1267. ]
  1268. export default remainingRouter