.umirc.ts 8.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328
  1. import { defineConfig } from '@umijs/max';
  2. export default defineConfig({
  3. hash: true,
  4. antd: {},
  5. access: {},
  6. model: {},
  7. initialState: {},
  8. request: {},
  9. dva: {},
  10. layout: false,
  11. // publicPath: process.env.NODE_ENV == 'development' ? '/' : '/gt-dig/',
  12. publicPath: '/',
  13. metas: [
  14. // 配置html禁止缓存
  15. { 'http-equiv': 'pragma', content: 'no-cache' },
  16. { 'http-equiv': 'cache-control', content: 'no-cache' },
  17. { 'http-equiv': 'expires', content: '0' },
  18. { 'http-equiv': 'X-UA-Compatible', content: 'IE=EmulateIE9' },
  19. { name: 'transparent', content: 'true' },
  20. {
  21. name: 'viewport',
  22. content:
  23. 'width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=0',
  24. },
  25. ],
  26. headScripts: [`/rem.js`],
  27. proxy: {
  28. '/api': {
  29. // target: 'http://47.96.12.136:8888/',
  30. target: 'http://47.96.12.136:8788/',
  31. // target: 'http://120.55.44.4:8900/',
  32. //target: 'https://metawant.greentech.com.cn/',
  33. changeOrigin: true,
  34. },
  35. },
  36. routes: [
  37. {
  38. path: '/',
  39. redirect: '/home/92',
  40. },
  41. {
  42. name: '首页',
  43. path: '/home/:projectId',
  44. component: './Home',
  45. },
  46. {
  47. name: '项目选择',
  48. path: '/projects',
  49. component: './Projects',
  50. },
  51. {
  52. name: '菜单栏',
  53. path: '/menu/:projectId',
  54. component: './Menu',
  55. },
  56. {
  57. name: '水量监测',
  58. path: '/home/water-amt-mng/:projectId',
  59. component: './Home/WaterAmtMng',
  60. },
  61. {
  62. name: '水质监测',
  63. path: '/home/water-quality-mng/:projectId',
  64. component: './Home/QualityMng',
  65. },
  66. {
  67. name: '能耗监测',
  68. path: '/home/energy/:projectId',
  69. component: './Home/EnergyCostComparison',
  70. },
  71. {
  72. name: '能耗详情',
  73. path: '/home/energy/detail/:projectId',
  74. component: './Home/EnergyCostDetail',
  75. },
  76. {
  77. name: '药耗监测',
  78. path: '/home/chem-cost/:projectId',
  79. component: './Home/ChemCostComparison',
  80. },
  81. {
  82. name: '工况管理',
  83. path: '/smart/work/:projectId',
  84. component: './Smart',
  85. },
  86. {
  87. name: '工况评估',
  88. path: '/smart/condition-detection/:projectId',
  89. component: './Smart/ConditionDetection',
  90. },
  91. {
  92. name: '优化任务',
  93. path: '/smart/optimization-tasks/:projectId',
  94. component: './Smart/OptimizationTasks',
  95. },
  96. {
  97. name: '模拟仿真',
  98. path: '/smart/simulate/:projectId',
  99. component: './Smart/Simulate',
  100. },
  101. {
  102. name: '智能管控',
  103. path: '/controller/:projectId',
  104. component: './Controller',
  105. },
  106. {
  107. name: '感知监控',
  108. path: '/controller/hardware/:projectId',
  109. component: './Controller/Hardware',
  110. },
  111. {
  112. name: '设备定位',
  113. path: '/controller/device/:projectId',
  114. component: './Controller/Device',
  115. },
  116. // {
  117. // name: '空调监控',
  118. // path: '/hardware-controller/air-conditioner/:projectId',
  119. // component: './Controller/AirConditioner',
  120. // },
  121. // {
  122. // name: '灯光监控',
  123. // path: '/hardware-controller/light/:projectId',
  124. // component: './Controller/Light',
  125. // },
  126. {
  127. name: '系统自检',
  128. path: '/self-inspection/:projectId',
  129. component: './EqSelfInspection',
  130. },
  131. {
  132. name: '自检列表',
  133. path: '/self-inspection/list/:projectId',
  134. component: './EqSelfInspection/List',
  135. },
  136. {
  137. name: '自检报告',
  138. path: '/self-inspection/detail/:projectId/:routeId',
  139. component: './EqSelfInspection/ReportDetail',
  140. },
  141. {
  142. name: '自检统计',
  143. path: '/self-inspection/statistics/:projectId',
  144. component: './EqSelfInspection/Statistics',
  145. },
  146. {
  147. name: '任务管理 - 工单管理',
  148. path: '/task-manage/:projectID',
  149. component: './TaskManage',
  150. },
  151. {
  152. name: '任务列表',
  153. path: '/task-manage/list',
  154. component: './TaskManage/Detail/TaskList/TaskList',
  155. },
  156. {
  157. name: '任务详情',
  158. path: '/task-manage/list/detail',
  159. component: './TaskManage/Detail/TaskDetail/TaskDetail',
  160. },
  161. {
  162. name: '工单列表',
  163. path: '/task-manage/work-order/list',
  164. component: './TaskManage/Detail/WorkOrderList/WorkOrderList',
  165. },
  166. {
  167. name: '任务关联工单详情',
  168. path: '/task-manage/list/order-detail',
  169. component: './TaskManage/Detail/TaskOrder/TaskOrder',
  170. },
  171. {
  172. name: '任务弹窗',
  173. path: '/task-manage/pop/:projectID',
  174. component: './TaskManage/Popup',
  175. },
  176. {
  177. name: '工单详情弹窗',
  178. path: '/task-manage/pop/work-order/:projectID',
  179. component: './TaskManage/Popup/WorkOrderModal',
  180. },
  181. {
  182. name: '消息中心',
  183. path: '/message/:projectId',
  184. component: './MessageCenter',
  185. },
  186. {
  187. name: '设备管理',
  188. path: '/device/:projectId',
  189. component: './DeviceManager',
  190. },
  191. {
  192. name: '出入库管理详情',
  193. path: '/device/detail/:projectId/:type',
  194. component: './DeviceManager/detail',
  195. },
  196. {
  197. name: '备品管理总览',
  198. path: '/device/spare-part/:projectId',
  199. component: './DeviceManager/sparePart',
  200. },
  201. {
  202. name: '安全管理',
  203. path: '/safety/:projectId', ///safety management
  204. component: './SafetyManagement',
  205. },
  206. {
  207. name: '安全管理-口令',
  208. path: '/safety/command/:projectId', ///safety management
  209. component: './SafetyManagement/Command',
  210. },
  211. // 视频图片预览
  212. {
  213. path: '/alarm/preview',
  214. name: '',
  215. component: './Alarm/Preview',
  216. },
  217. {
  218. name: '门禁日志',
  219. path: '/safety/detail/:projectId', ///safety management
  220. component: './SafetyManagement/doorDetail',
  221. },
  222. // 智慧运营
  223. {
  224. name: '',
  225. path: '/smart-ops/:projectId', ///safety management
  226. component: './SmartOps/index',
  227. },
  228. // 工况分析详情
  229. {
  230. name: '',
  231. path: '/smart-ops/work-analysis-detail/:projectId', ///safety management
  232. component: './SmartOps/WorkAnalysisDetail',
  233. },
  234. // 历史记录
  235. {
  236. name: '',
  237. path: '/smart-ops/history-record/:projectId', ///safety management
  238. component: './SmartOps/HistoryRecord',
  239. },
  240. // 操作记录
  241. {
  242. name: '',
  243. path: '/smart-ops/operation-record/:projectId',
  244. component: './SmartOps/OperationRecord',
  245. },
  246. // 图标弹窗页面
  247. {
  248. name: '',
  249. path: '/smart-ops/chart-page/:projectId',
  250. component: './SmartOps/ChartPage',
  251. },
  252. // 预测分析图表页面
  253. {
  254. name: '',
  255. path: '/smart-ops/prediction/:projectId',
  256. component: './SmartOps/predictionAnalysis/PredictionDetail',
  257. },
  258. // 系统工作日报
  259. {
  260. name: '',
  261. path: '/system-daily/:projectId',
  262. component: './SystemDaily/index',
  263. },
  264. //个人中心
  265. {
  266. name: '个人中心',
  267. path: '/center/:projectId',
  268. component: './Center/index',
  269. },
  270. {
  271. name: '我的任务',
  272. path: '/center/my-task/:projectId',
  273. component: './Center/MyTask',
  274. },
  275. {
  276. name: '我的任务列表',
  277. path: '/center/my-task/task-list',
  278. component: './Center/MyTask/List/TaskList',
  279. },
  280. {
  281. name: '我的工单列表',
  282. path: '/center/my-task/work-order-list',
  283. component: './Center/MyTask/List/WorkOrderList',
  284. },
  285. {
  286. name: '我的任务详情',
  287. path: '/center/my-task/task-detail',
  288. component: './Center/MyTask/Detail/TaskDetail',
  289. },
  290. {
  291. name: '我的工单详情',
  292. path: '/center/my-task/work-order-detail',
  293. component: './Center/MyTask/Detail/WorkOrderDetail',
  294. },
  295. //智慧运营报告
  296. {
  297. name: '',
  298. path: '/smart-report/:projectId',
  299. component: './SmartReport/index',
  300. },
  301. //设备采购文件列表
  302. {
  303. path: '/device/equipment-procurement-list/:projectId/:billId/:deviceCode/:fileType/:ops',
  304. name: '',
  305. component: './DeviceManager/EquipmentProcurementList',
  306. },
  307. //设备施工文件列表
  308. {
  309. path: '/device/equipment-construction-list/:projectId/:code/:fileType/:ops',
  310. name: '',
  311. component: './DeviceManager/EquipmentConstructionList',
  312. },
  313. //设备保养详情
  314. {
  315. path: '/device/maintain-detail',
  316. name: '',
  317. component: './DeviceManager/deviceMaintainDetail',
  318. },
  319. //设备维修详情
  320. {
  321. path: '/device/repair-detail',
  322. name: '',
  323. component: './DeviceManager/deviceRepairDetail',
  324. },
  325. ],
  326. npmClient: 'yarn',
  327. });