openatc-components 0.1.18 → 0.1.19

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (384) hide show
  1. package/.babelrc +18 -18
  2. package/.editorconfig +9 -9
  3. package/.eslintignore +5 -5
  4. package/.eslintrc.js +29 -29
  5. package/.postcssrc.js +10 -10
  6. package/README.md +30 -30
  7. package/build/build.js +41 -41
  8. package/build/check-versions.js +54 -54
  9. package/build/package.config.js +58 -58
  10. package/build/package.dev.config.js +107 -107
  11. package/build/package.prod.config.js +160 -160
  12. package/build/utils.js +101 -101
  13. package/build/vue-loader.conf.js +22 -22
  14. package/build/webpack.base.conf.js +114 -114
  15. package/build/webpack.dev.conf.js +95 -95
  16. package/build/webpack.prod.conf.js +149 -149
  17. package/config/dev.env.js +8 -8
  18. package/config/index.js +91 -91
  19. package/config/prod.env.js +5 -5
  20. package/config/test.env.js +7 -7
  21. package/index.html +12 -12
  22. package/package/kisscomps/components/BoardCard/BoardCard.vue +94 -94
  23. package/package/kisscomps/components/BoardCard/index.js +2 -2
  24. package/package/kisscomps/components/Channelization/Channelization.vue +544 -544
  25. package/package/kisscomps/components/Channelization/index.js +2 -2
  26. package/package/kisscomps/components/ChannelizationFlowStatistic/ChannelizationFlowStatistic.vue +349 -349
  27. package/package/kisscomps/components/ChannelizationFlowStatistic/index.js +2 -2
  28. package/package/kisscomps/components/ChannelizationWithInterface/ChannelizationWithInterface.vue +486 -486
  29. package/package/kisscomps/components/ChannelizationWithInterface/index.js +2 -2
  30. package/package/kisscomps/components/CommonKanban/CommonKanban.vue +118 -118
  31. package/package/kisscomps/components/CommonKanban/index.js +2 -2
  32. package/package/kisscomps/components/DrawChannelization/drawsvg/basicCoordInfo.vue +165 -165
  33. package/package/kisscomps/components/DrawChannelization/drawsvg/channelizationElements.vue +255 -255
  34. package/package/kisscomps/components/DrawChannelization/drawsvg/detectorAssociatedComponent.vue +152 -152
  35. package/package/kisscomps/components/DrawChannelization/drawsvg/drawElement/TextBox.vue +91 -91
  36. package/package/kisscomps/components/DrawChannelization/drawsvg/drawElement/crossMap.vue +194 -194
  37. package/package/kisscomps/components/DrawChannelization/drawsvg/drawElement/editText.vue +108 -108
  38. package/package/kisscomps/components/DrawChannelization/drawsvg/firstImportCrossmap.vue +51 -51
  39. package/package/kisscomps/components/DrawChannelization/drawsvg/iconSvg/countdownSvg.vue +236 -236
  40. package/package/kisscomps/components/DrawChannelization/drawsvg/iconSvg/detectorChart.vue +247 -247
  41. package/package/kisscomps/components/DrawChannelization/drawsvg/iconSvg/detectorIconSvg.vue +210 -210
  42. package/package/kisscomps/components/DrawChannelization/drawsvg/iconSvg/laneIcon.vue +72 -72
  43. package/package/kisscomps/components/DrawChannelization/drawsvg/iconSvg/motorwayIconSvg.vue +455 -455
  44. package/package/kisscomps/components/DrawChannelization/drawsvg/iconSvg/pedroadIconSvg.vue +219 -219
  45. package/package/kisscomps/components/DrawChannelization/drawsvg/importDialog.vue +74 -74
  46. package/package/kisscomps/components/DrawChannelization/drawsvg/index.draw.vue +1002 -1002
  47. package/package/kisscomps/components/DrawChannelization/drawsvg/index.vue +110 -110
  48. package/package/kisscomps/components/DrawChannelization/drawsvg/laneEditPanel.vue +699 -699
  49. package/package/kisscomps/components/DrawChannelization/drawsvg/overlapAssociatedComponent.vue +157 -157
  50. package/package/kisscomps/components/DrawChannelization/drawsvg/phaseAssociatedComponent.vue +157 -157
  51. package/package/kisscomps/components/DrawChannelization/drawsvg/table.vue +99 -99
  52. package/package/kisscomps/components/DrawChannelization/drawsvg/utils/loadutils.js +87 -87
  53. package/package/kisscomps/components/DrawChannelization/drawsvg/utils/phaseDataModel.js +32 -32
  54. package/package/kisscomps/components/DrawChannelization/drawsvg/utils/phasePos.json +20 -20
  55. package/package/kisscomps/components/DrawChannelization/index.js +2 -2
  56. package/package/kisscomps/components/DrawChannelization/phaseDataMgr.js +278 -278
  57. package/package/kisscomps/components/ExpendConfig/ExpendConfig.vue +114 -114
  58. package/package/kisscomps/components/ExpendConfig/index.js +2 -2
  59. package/package/kisscomps/components/FaultDetailModal/FaultDetailModal.vue +170 -170
  60. package/package/kisscomps/components/FaultDetailModal/index.js +2 -2
  61. package/package/kisscomps/components/IntersectionMap/crossDirection/baseImg/CrossRoadsSvg.vue +497 -497
  62. package/package/kisscomps/components/IntersectionMap/crossDirection/baseImg/CustomRoadsSvg.vue +46 -46
  63. package/package/kisscomps/components/IntersectionMap/crossDirection/baseImg/PedSectionEWSvg.vue +300 -300
  64. package/package/kisscomps/components/IntersectionMap/crossDirection/baseImg/PedSectionSNSvg.vue +288 -288
  65. package/package/kisscomps/components/IntersectionMap/crossDirection/baseImg/RampEastSvg.vue +391 -391
  66. package/package/kisscomps/components/IntersectionMap/crossDirection/baseImg/RampNorthSvg.vue +336 -336
  67. package/package/kisscomps/components/IntersectionMap/crossDirection/baseImg/RampSouthSvg.vue +345 -345
  68. package/package/kisscomps/components/IntersectionMap/crossDirection/baseImg/RampWestSvg.vue +389 -389
  69. package/package/kisscomps/components/IntersectionMap/crossDirection/baseImg/SidewalkSvg.vue +1179 -1179
  70. package/package/kisscomps/components/IntersectionMap/crossDirection/baseImg/TShapeEastRoadsSvg.vue +402 -402
  71. package/package/kisscomps/components/IntersectionMap/crossDirection/baseImg/TShapeNorthRoadsSvg.vue +361 -361
  72. package/package/kisscomps/components/IntersectionMap/crossDirection/baseImg/TShapeSouthRoadsSvg.vue +368 -368
  73. package/package/kisscomps/components/IntersectionMap/crossDirection/baseImg/TShapeWestRoadsSvg.vue +475 -475
  74. package/package/kisscomps/components/IntersectionMap/crossDirection/baseImg/leftroad/LCrossRoadsSvg.vue +494 -494
  75. package/package/kisscomps/components/IntersectionMap/crossDirection/baseImg/leftroad/LTShapeEastRoadsSvg.vue +401 -401
  76. package/package/kisscomps/components/IntersectionMap/crossDirection/baseImg/leftroad/LTShapeNorthRoadsSvg.vue +360 -360
  77. package/package/kisscomps/components/IntersectionMap/crossDirection/baseImg/leftroad/LTShapeSouthRoadsSvg.vue +367 -367
  78. package/package/kisscomps/components/IntersectionMap/crossDirection/baseImg/leftroad/LTShapeWestRoadsSvg.vue +476 -476
  79. package/package/kisscomps/components/IntersectionMap/crossDirection/baseImg/refreshSvg.vue +63 -63
  80. package/package/kisscomps/components/IntersectionMap/crossDirection/busIcon/busMapSvg.vue +50 -50
  81. package/package/kisscomps/components/IntersectionMap/crossDirection/busIcon/eastBusSvg.vue +167 -167
  82. package/package/kisscomps/components/IntersectionMap/crossDirection/busIcon/northBusSvg.vue +168 -168
  83. package/package/kisscomps/components/IntersectionMap/crossDirection/busIcon/southBusSvg.vue +168 -168
  84. package/package/kisscomps/components/IntersectionMap/crossDirection/busIcon/westBusSvg.vue +169 -169
  85. package/package/kisscomps/components/IntersectionMap/crossDirection/crossDiagram.vue +920 -920
  86. package/package/kisscomps/components/IntersectionMap/crossDirection/phaseIcon/LphaseIconSvg.vue +112 -112
  87. package/package/kisscomps/components/IntersectionMap/crossDirection/phaseIcon/phaseIconSvg.vue +112 -112
  88. package/package/kisscomps/components/IntersectionMap/crossDirection/phaseIcon/rampPhaseIconSvg.vue +111 -111
  89. package/package/kisscomps/components/IntersectionMap/crossDirection/posJson/busPos.json +196 -196
  90. package/package/kisscomps/components/IntersectionMap/crossDirection/posJson/busPos.left.json +196 -196
  91. package/package/kisscomps/components/IntersectionMap/crossDirection/posJson/phasePos.json +99 -99
  92. package/package/kisscomps/components/IntersectionMap/crossDirection/posJson/phasePos.left.json +99 -99
  93. package/package/kisscomps/components/IntersectionMap/crossDirection/posJson/rampPos.json +52 -52
  94. package/package/kisscomps/components/IntersectionMap/crossDirection/posJson/sidePos.json +99 -99
  95. package/package/kisscomps/components/IntersectionMap/crossDirection/utils.js +78 -78
  96. package/package/kisscomps/components/IntersectionMap/index.js +2 -2
  97. package/package/kisscomps/components/IntersectionMap/intersectionmap.vue +159 -159
  98. package/package/kisscomps/components/IntersectionWithInterface/IntersectionWithInterface.vue +521 -521
  99. package/package/kisscomps/components/IntersectionWithInterface/index.js +2 -2
  100. package/package/kisscomps/components/KanBan/index.js +2 -2
  101. package/package/kisscomps/components/KanBan/kanban.vue +219 -219
  102. package/package/kisscomps/components/MessageBox/index.vue +96 -96
  103. package/package/kisscomps/components/OverLap/OverLap.vue +207 -207
  104. package/package/kisscomps/components/OverLap/index.js +2 -2
  105. package/package/kisscomps/components/PatternStatus/PatternStatus.vue +962 -962
  106. package/package/kisscomps/components/PatternStatus/index.js +2 -2
  107. package/package/kisscomps/components/PatternWalkSvg/PatternWalkSvg.vue +423 -423
  108. package/package/kisscomps/components/PatternWalkSvg/index.js +2 -2
  109. package/package/kisscomps/components/PhaseMarker/index.js +6 -6
  110. package/package/kisscomps/components/PhaseMarker/phasemarker.vue +215 -215
  111. package/package/kisscomps/components/PhaseMarker/svg/patternSvg.vue +121 -121
  112. package/package/kisscomps/components/PhaseMarker/svg/phase.vue +60 -60
  113. package/package/kisscomps/components/PhaseMarker/svg/phaseCount.vue +62 -62
  114. package/package/kisscomps/components/PhaseMarker/svg/phaseCountCycle.vue +62 -62
  115. package/package/kisscomps/components/PhaseMarker/svg/phaseSvg.vue +117 -117
  116. package/package/kisscomps/components/SchemeConfig/SchemeConfig.vue +779 -779
  117. package/package/kisscomps/components/SchemeConfig/closePhaselControlModal/index.vue +195 -195
  118. package/package/kisscomps/components/SchemeConfig/index.js +2 -2
  119. package/package/kisscomps/components/SchemeConfig/lockingPhaselControlModal/index.vue +198 -198
  120. package/package/kisscomps/components/SchemeConfig/manualControlModal/index.vue +226 -226
  121. package/package/kisscomps/components/SchemeConfig/priorityControl/index.vue +198 -198
  122. package/package/kisscomps/components/SchemeConfig/priorityControl/utils.js +163 -163
  123. package/package/kisscomps/components/SchemeConfig/realtimeStatusModal/index.vue +275 -275
  124. package/package/kisscomps/components/SchemeConfig/tentativeplancontrolmodal/index.vue +574 -1395
  125. package/package/kisscomps/components/StageBord/StageBord.vue +242 -242
  126. package/package/kisscomps/components/StageBord/index.js +2 -2
  127. package/package/kisscomps/components/StageStatus/StageStatus.vue +310 -310
  128. package/package/kisscomps/components/StageStatus/index.js +2 -2
  129. package/package/kisscomps/components/Stages/index.vue +139 -139
  130. package/package/kisscomps/components/SvgIcon/SvgIcon.vue +53 -53
  131. package/package/kisscomps/components/SvgIcon/index.js +2 -2
  132. package/package/kisscomps/components/XRDDirSelector/XRDDirSelector.vue +522 -522
  133. package/package/kisscomps/components/XRDDirSelector/index.js +2 -2
  134. package/package/kisscomps/components/overView/index.vue +687 -687
  135. package/package/kisscomps/components/patternList/index.js +2 -2
  136. package/package/kisscomps/components/patternList/patternList.vue +567 -567
  137. package/package/kisscomps/index.js +109 -109
  138. package/package/kissui.min.js +1 -1
  139. package/package.json +126 -128
  140. package/src/App.vue +24 -24
  141. package/src/EdgeMgr/EdgeModelBase.js +16 -16
  142. package/src/EdgeMgr/controller/crossDiagramMgr.js +120 -120
  143. package/src/api/authapi.js +31 -31
  144. package/src/api/config.js +21 -21
  145. package/src/api/control.js +76 -76
  146. package/src/api/cross.js +33 -33
  147. package/src/api/fault.js +66 -66
  148. package/src/api/index.js +24 -24
  149. package/src/api/login.js +46 -46
  150. package/src/api/optimize.js +72 -72
  151. package/src/api/param.js +154 -154
  152. package/src/api/passwdAssest.js +101 -101
  153. package/src/api/template.js +27 -27
  154. package/src/i18n/index.js +26 -26
  155. package/src/i18n/language/en.js +1227 -1227
  156. package/src/i18n/language/index.js +25 -25
  157. package/src/i18n/language/zh.js +1226 -1226
  158. package/src/icons/demo.css +539 -539
  159. package/src/icons/iconfont.css +835 -835
  160. package/src/icons/iconfont.json +1444 -1444
  161. package/src/icons/index.js +20 -20
  162. package/src/icons/svg/bendi.svg +110 -110
  163. package/src/icons/svg/bujin.svg +36 -36
  164. package/src/icons/svg/connectBlue.svg +7 -7
  165. package/src/icons/svg/currentvolume.svg +0 -0
  166. package/src/icons/svg/custom-BRTlane.svg +40 -40
  167. package/src/icons/svg/custom-buslane.svg +40 -40
  168. package/src/icons/svg/custom-detector.svg +12 -12
  169. package/src/icons/svg/custom-east-bottom.svg +32 -32
  170. package/src/icons/svg/custom-east-top.svg +32 -32
  171. package/src/icons/svg/custom-ewped.svg +35 -35
  172. package/src/icons/svg/custom-nonmotorizedlane.svg +40 -40
  173. package/src/icons/svg/custom-north-left.svg +32 -32
  174. package/src/icons/svg/custom-north-right.svg +32 -32
  175. package/src/icons/svg/custom-peddetector.svg +17 -17
  176. package/src/icons/svg/custom-snped.svg +35 -35
  177. package/src/icons/svg/custom-south-left.svg +32 -32
  178. package/src/icons/svg/custom-south-right.svg +32 -32
  179. package/src/icons/svg/custom-tramlane.svg +40 -40
  180. package/src/icons/svg/custom-vehiclebranch.svg +40 -40
  181. package/src/icons/svg/custom-vehiclemainroad.svg +41 -41
  182. package/src/icons/svg/custom-west-bottom.svg +32 -32
  183. package/src/icons/svg/custom-west-top.svg +32 -32
  184. package/src/icons/svg/custom-xlped.svg +14 -14
  185. package/src/icons/svg/custom-xrped.svg +14 -14
  186. package/src/icons/svg/cutRed.svg +7 -7
  187. package/src/icons/svg/cycle.svg +0 -0
  188. package/src/icons/svg/dingzhouqi.svg +34 -34
  189. package/src/icons/svg/ganyingkongzhi.svg +30 -30
  190. package/src/icons/svg/guandeng.svg +81 -81
  191. package/src/icons/svg/huangshan.svg +71 -71
  192. package/src/icons/svg/maincontrol.svg +0 -0
  193. package/src/icons/svg/manualcontrolbackground.svg +51 -51
  194. package/src/icons/svg/manualcontrolbackground1.svg +62 -62
  195. package/src/icons/svg/manualcontrolbackgrounden.svg +62 -62
  196. package/src/icons/svg/model.svg +0 -0
  197. package/src/icons/svg/phasediff.svg +0 -0
  198. package/src/icons/svg/quanhong.svg +86 -86
  199. package/src/icons/svg/shanghe.svg +11 -11
  200. package/src/icons/svg/shoudong.svg +103 -103
  201. package/src/icons/svg/time.svg +0 -0
  202. package/src/icons/svg/wuxianlan.svg +46 -46
  203. package/src/icons/svg/xiala.svg +11 -11
  204. package/src/icons/svg/xingrenguojie.svg +33 -33
  205. package/src/icons/svg/xitong.svg +89 -89
  206. package/src/icons/svg/youxian.svg +41 -41
  207. package/src/icons/svg/zizhukongzhi.svg +43 -43
  208. package/src/kisscomps/components/BoardCard/BoardCard.vue +94 -94
  209. package/src/kisscomps/components/BoardCard/index.js +2 -2
  210. package/src/kisscomps/components/Channelization/Channelization.vue +544 -544
  211. package/src/kisscomps/components/Channelization/index.js +2 -2
  212. package/src/kisscomps/components/ChannelizationFlowStatistic/ChannelizationFlowStatistic.vue +349 -349
  213. package/src/kisscomps/components/ChannelizationFlowStatistic/index.js +2 -2
  214. package/src/kisscomps/components/ChannelizationWithInterface/ChannelizationWithInterface.vue +486 -486
  215. package/src/kisscomps/components/ChannelizationWithInterface/index.js +2 -2
  216. package/src/kisscomps/components/CommonKanban/CommonKanban.vue +118 -118
  217. package/src/kisscomps/components/CommonKanban/index.js +2 -2
  218. package/src/kisscomps/components/DrawChannelization/drawsvg/basicCoordInfo.vue +165 -165
  219. package/src/kisscomps/components/DrawChannelization/drawsvg/channelizationElements.vue +255 -255
  220. package/src/kisscomps/components/DrawChannelization/drawsvg/detectorAssociatedComponent.vue +152 -152
  221. package/src/kisscomps/components/DrawChannelization/drawsvg/drawElement/TextBox.vue +91 -91
  222. package/src/kisscomps/components/DrawChannelization/drawsvg/drawElement/crossMap.vue +194 -194
  223. package/src/kisscomps/components/DrawChannelization/drawsvg/drawElement/editText.vue +108 -108
  224. package/src/kisscomps/components/DrawChannelization/drawsvg/firstImportCrossmap.vue +51 -51
  225. package/src/kisscomps/components/DrawChannelization/drawsvg/iconSvg/countdownSvg.vue +236 -236
  226. package/src/kisscomps/components/DrawChannelization/drawsvg/iconSvg/detectorChart.vue +247 -247
  227. package/src/kisscomps/components/DrawChannelization/drawsvg/iconSvg/detectorIconSvg.vue +210 -210
  228. package/src/kisscomps/components/DrawChannelization/drawsvg/iconSvg/laneIcon.vue +72 -72
  229. package/src/kisscomps/components/DrawChannelization/drawsvg/iconSvg/motorwayIconSvg.vue +455 -455
  230. package/src/kisscomps/components/DrawChannelization/drawsvg/iconSvg/pedroadIconSvg.vue +219 -219
  231. package/src/kisscomps/components/DrawChannelization/drawsvg/importDialog.vue +74 -74
  232. package/src/kisscomps/components/DrawChannelization/drawsvg/index.draw.vue +1002 -1002
  233. package/src/kisscomps/components/DrawChannelization/drawsvg/index.vue +110 -110
  234. package/src/kisscomps/components/DrawChannelization/drawsvg/laneEditPanel.vue +699 -699
  235. package/src/kisscomps/components/DrawChannelization/drawsvg/overlapAssociatedComponent.vue +157 -157
  236. package/src/kisscomps/components/DrawChannelization/drawsvg/phaseAssociatedComponent.vue +157 -157
  237. package/src/kisscomps/components/DrawChannelization/drawsvg/table.vue +99 -99
  238. package/src/kisscomps/components/DrawChannelization/drawsvg/utils/loadutils.js +87 -87
  239. package/src/kisscomps/components/DrawChannelization/drawsvg/utils/phaseDataModel.js +32 -32
  240. package/src/kisscomps/components/DrawChannelization/drawsvg/utils/phasePos.json +20 -20
  241. package/src/kisscomps/components/DrawChannelization/index.js +2 -2
  242. package/src/kisscomps/components/DrawChannelization/phaseDataMgr.js +278 -278
  243. package/src/kisscomps/components/ExpendConfig/ExpendConfig.vue +114 -114
  244. package/src/kisscomps/components/ExpendConfig/index.js +2 -2
  245. package/src/kisscomps/components/FaultDetailModal/FaultDetailModal.vue +170 -170
  246. package/src/kisscomps/components/FaultDetailModal/index.js +2 -2
  247. package/src/kisscomps/components/IntersectionMap/crossDirection/baseImg/CrossRoadsSvg.vue +497 -497
  248. package/src/kisscomps/components/IntersectionMap/crossDirection/baseImg/CustomRoadsSvg.vue +46 -46
  249. package/src/kisscomps/components/IntersectionMap/crossDirection/baseImg/PedSectionEWSvg.vue +300 -300
  250. package/src/kisscomps/components/IntersectionMap/crossDirection/baseImg/PedSectionSNSvg.vue +288 -288
  251. package/src/kisscomps/components/IntersectionMap/crossDirection/baseImg/RampEastSvg.vue +391 -391
  252. package/src/kisscomps/components/IntersectionMap/crossDirection/baseImg/RampNorthSvg.vue +336 -336
  253. package/src/kisscomps/components/IntersectionMap/crossDirection/baseImg/RampSouthSvg.vue +345 -345
  254. package/src/kisscomps/components/IntersectionMap/crossDirection/baseImg/RampWestSvg.vue +389 -389
  255. package/src/kisscomps/components/IntersectionMap/crossDirection/baseImg/SidewalkSvg.vue +1179 -1179
  256. package/src/kisscomps/components/IntersectionMap/crossDirection/baseImg/TShapeEastRoadsSvg.vue +402 -402
  257. package/src/kisscomps/components/IntersectionMap/crossDirection/baseImg/TShapeNorthRoadsSvg.vue +361 -361
  258. package/src/kisscomps/components/IntersectionMap/crossDirection/baseImg/TShapeSouthRoadsSvg.vue +368 -368
  259. package/src/kisscomps/components/IntersectionMap/crossDirection/baseImg/TShapeWestRoadsSvg.vue +475 -475
  260. package/src/kisscomps/components/IntersectionMap/crossDirection/baseImg/leftroad/LCrossRoadsSvg.vue +494 -494
  261. package/src/kisscomps/components/IntersectionMap/crossDirection/baseImg/leftroad/LTShapeEastRoadsSvg.vue +401 -401
  262. package/src/kisscomps/components/IntersectionMap/crossDirection/baseImg/leftroad/LTShapeNorthRoadsSvg.vue +360 -360
  263. package/src/kisscomps/components/IntersectionMap/crossDirection/baseImg/leftroad/LTShapeSouthRoadsSvg.vue +367 -367
  264. package/src/kisscomps/components/IntersectionMap/crossDirection/baseImg/leftroad/LTShapeWestRoadsSvg.vue +476 -476
  265. package/src/kisscomps/components/IntersectionMap/crossDirection/baseImg/refreshSvg.vue +63 -63
  266. package/src/kisscomps/components/IntersectionMap/crossDirection/busIcon/busMapSvg.vue +50 -50
  267. package/src/kisscomps/components/IntersectionMap/crossDirection/busIcon/eastBusSvg.vue +167 -167
  268. package/src/kisscomps/components/IntersectionMap/crossDirection/busIcon/northBusSvg.vue +168 -168
  269. package/src/kisscomps/components/IntersectionMap/crossDirection/busIcon/southBusSvg.vue +168 -168
  270. package/src/kisscomps/components/IntersectionMap/crossDirection/busIcon/westBusSvg.vue +169 -169
  271. package/src/kisscomps/components/IntersectionMap/crossDirection/crossDiagram.vue +920 -920
  272. package/src/kisscomps/components/IntersectionMap/crossDirection/phaseIcon/LphaseIconSvg.vue +112 -112
  273. package/src/kisscomps/components/IntersectionMap/crossDirection/phaseIcon/phaseIconSvg.vue +112 -112
  274. package/src/kisscomps/components/IntersectionMap/crossDirection/phaseIcon/rampPhaseIconSvg.vue +111 -111
  275. package/src/kisscomps/components/IntersectionMap/crossDirection/posJson/busPos.json +196 -196
  276. package/src/kisscomps/components/IntersectionMap/crossDirection/posJson/busPos.left.json +196 -196
  277. package/src/kisscomps/components/IntersectionMap/crossDirection/posJson/phasePos.json +99 -99
  278. package/src/kisscomps/components/IntersectionMap/crossDirection/posJson/phasePos.left.json +99 -99
  279. package/src/kisscomps/components/IntersectionMap/crossDirection/posJson/rampPos.json +52 -52
  280. package/src/kisscomps/components/IntersectionMap/crossDirection/posJson/sidePos.json +99 -99
  281. package/src/kisscomps/components/IntersectionMap/crossDirection/utils.js +78 -78
  282. package/src/kisscomps/components/IntersectionMap/index.js +2 -2
  283. package/src/kisscomps/components/IntersectionMap/intersectionmap.vue +159 -159
  284. package/src/kisscomps/components/IntersectionWithInterface/IntersectionWithInterface.vue +521 -521
  285. package/src/kisscomps/components/IntersectionWithInterface/index.js +2 -2
  286. package/src/kisscomps/components/KanBan/index.js +2 -2
  287. package/src/kisscomps/components/KanBan/kanban.vue +219 -219
  288. package/src/kisscomps/components/MessageBox/index.vue +96 -96
  289. package/src/kisscomps/components/OverLap/OverLap.vue +207 -207
  290. package/src/kisscomps/components/OverLap/index.js +2 -2
  291. package/src/kisscomps/components/PatternStatus/PatternStatus.vue +962 -962
  292. package/src/kisscomps/components/PatternStatus/index.js +2 -2
  293. package/src/kisscomps/components/PatternWalkSvg/PatternWalkSvg.vue +423 -423
  294. package/src/kisscomps/components/PatternWalkSvg/index.js +2 -2
  295. package/src/kisscomps/components/PhaseMarker/index.js +6 -6
  296. package/src/kisscomps/components/PhaseMarker/phasemarker.vue +215 -215
  297. package/src/kisscomps/components/PhaseMarker/svg/patternSvg.vue +121 -121
  298. package/src/kisscomps/components/PhaseMarker/svg/phase.vue +60 -60
  299. package/src/kisscomps/components/PhaseMarker/svg/phaseCount.vue +62 -62
  300. package/src/kisscomps/components/PhaseMarker/svg/phaseCountCycle.vue +62 -62
  301. package/src/kisscomps/components/PhaseMarker/svg/phaseSvg.vue +117 -117
  302. package/src/kisscomps/components/SchemeConfig/SchemeConfig.vue +779 -779
  303. package/src/kisscomps/components/SchemeConfig/closePhaselControlModal/index.vue +195 -195
  304. package/src/kisscomps/components/SchemeConfig/index.js +2 -2
  305. package/src/kisscomps/components/SchemeConfig/lockingPhaselControlModal/index.vue +198 -198
  306. package/src/kisscomps/components/SchemeConfig/manualControlModal/index.vue +226 -226
  307. package/src/kisscomps/components/SchemeConfig/priorityControl/index.vue +198 -198
  308. package/src/kisscomps/components/SchemeConfig/priorityControl/utils.js +163 -163
  309. package/src/kisscomps/components/SchemeConfig/realtimeStatusModal/index.vue +275 -275
  310. package/src/kisscomps/components/SchemeConfig/tentativeplancontrolmodal/index.vue +574 -1395
  311. package/src/kisscomps/components/StageBord/StageBord.vue +242 -242
  312. package/src/kisscomps/components/StageBord/index.js +2 -2
  313. package/src/kisscomps/components/StageStatus/StageStatus.vue +310 -310
  314. package/src/kisscomps/components/StageStatus/index.js +2 -2
  315. package/src/kisscomps/components/Stages/index.vue +139 -139
  316. package/src/kisscomps/components/SvgIcon/SvgIcon.vue +53 -53
  317. package/src/kisscomps/components/SvgIcon/index.js +2 -2
  318. package/src/kisscomps/components/XRDDirSelector/XRDDirSelector.vue +522 -522
  319. package/src/kisscomps/components/XRDDirSelector/index.js +2 -2
  320. package/src/kisscomps/components/overView/index.vue +687 -687
  321. package/src/kisscomps/components/patternList/index.js +2 -2
  322. package/src/kisscomps/components/patternList/patternList.vue +567 -567
  323. package/src/kisscomps/index.js +109 -109
  324. package/src/lib/publicjs/ArryListUtil.js +38 -38
  325. package/src/lib/publicjs/HttpurlMgr.js +45 -45
  326. package/src/lib/publicjs/KissApi.js +158 -158
  327. package/src/lib/publicjs/KissWSSub/Heartcheck.js +128 -128
  328. package/src/lib/publicjs/KissWSSub/KissWsSub.js +91 -91
  329. package/src/lib/publicjs/KissWSSub/KissWsSubByType.js +152 -152
  330. package/src/lib/publicjs/KissWSSub/SimuWsSubByType.js +44 -44
  331. package/src/lib/publicjs/KissWSSub/Sub.js +51 -51
  332. package/src/lib/publicjs/KissWSSub/SubChannel.js +119 -119
  333. package/src/lib/publicjs/basecomponents.js +65 -65
  334. package/src/lib/publicjs/localStorage.js +112 -112
  335. package/src/lib/publicjs/objdeepcopy.js +32 -32
  336. package/src/lib/publicjs/pageScroll.js +30 -30
  337. package/src/lib/publicjs/passwdAssest.js +101 -101
  338. package/src/lib/publicjs/styleclassfactory.js +32 -32
  339. package/src/main.js +50 -50
  340. package/src/router/index.js +42 -42
  341. package/src/store/getters.js +16 -16
  342. package/src/store/index.js +26 -26
  343. package/src/store/modules/globalParam.js +67 -67
  344. package/src/utils/ControlFormat.js +68 -68
  345. package/src/utils/RingDataModel.js +191 -191
  346. package/src/utils/auth.js +178 -178
  347. package/src/utils/dateFormat.js +41 -41
  348. package/src/utils/errorcode.js +224 -224
  349. package/src/utils/fault.js +195 -195
  350. package/src/utils/faultcode.js +209 -209
  351. package/src/utils/index.js +69 -69
  352. package/src/utils/pedphasedesc.js +119 -119
  353. package/src/utils/phasedesc.js +124 -124
  354. package/src/utils/responseMessage.js +21 -21
  355. package/src/utils/validate.js +43 -43
  356. package/src/views/customchannelization.vue +49 -49
  357. package/src/views/home.1.vue +479 -479
  358. package/src/views/home.vue +78 -78
  359. package/src/views/intersection.vue +309 -309
  360. package/src/views/overView.vue +41 -41
  361. package/src/views/schemeconfig.vue +165 -165
  362. package/static/apiconfig.json +351 -351
  363. package/static/styles/channelizatioon.scss +414 -414
  364. package/static/styles/common.scss +20 -20
  365. package/static/styles/commonkanban.scss +87 -87
  366. package/static/styles/dark/index.scss +2 -2
  367. package/static/styles/dark/theme/element-dark.scss +42 -42
  368. package/static/styles/index.scss +84 -84
  369. package/static/styles/intersection.scss +170 -170
  370. package/static/styles/light/index.scss +2 -2
  371. package/static/styles/light/theme/element-light.scss +42 -42
  372. package/static/styles/overview.scss +371 -371
  373. package/static/styles/schemeconfig.scss +457 -457
  374. package/static/styles/stages.scss +64 -64
  375. package/static/token.json +2 -2
  376. package/test/e2e/custom-assertions/elementCount.js +27 -27
  377. package/test/e2e/nightwatch.conf.js +46 -46
  378. package/test/e2e/runner.js +48 -48
  379. package/test/e2e/specs/test.js +19 -19
  380. package/test/unit/.eslintrc +7 -7
  381. package/test/unit/jest.conf.js +30 -30
  382. package/test/unit/setup.js +3 -3
  383. package/test/unit/specs/HelloWorld.spec.js +11 -11
  384. package/pnpm-lock.yaml +0 -12352
@@ -1,1395 +1,574 @@
1
- <template>
2
- <div class="tentativeplan-control">
3
- <div class="title" style="margin-bottom: 18px;">{{$t('openatccomponents.overview.tentativeplan')}}</div>
4
- <el-row>
5
- <el-col :span="12">
6
- <el-form
7
- ref="manual"
8
- label-position="left"
9
- :model="manualInfo"
10
- label-width="100px">
11
- <el-form-item
12
- :label="$t('openatccomponents.overview.patternid') + ':'"
13
- prop="count">
14
- <el-select @change="selectPattern()" v-model="manualInfo.tempPatternid" class="col-inner" size="small" :placeholder="$t('openatccomponents.common.select')">
15
- <el-option
16
- v-for="item in patternSelect"
17
- :key="item.value"
18
- :value="item.desc">
19
- </el-option>
20
- </el-select>
21
- <!-- <el-input v-model="manualInfo.tempDuration" size="mini" :placeholder="$t('openatccomponents.common.input')"></el-input> -->
22
- </el-form-item>
23
- <el-form-item
24
- :label="$t('openatccomponents.overview.delay') + ':'"
25
- prop="intersection">
26
- <el-input-number :placeholder="$t('openatccomponents.common.input')" :min="0" :max="65535" :precision="0" :step="1" :controls="false" v-model.number="manualInfo.tempDelay" size="mini"></el-input-number>
27
- <!-- <el-input v-model="manualInfo.tempDelay" size="mini" :placeholder="$t('openatccomponents.common.input')"></el-input> -->
28
- </el-form-item>
29
- </el-form>
30
- </el-col>
31
- <el-col :span="12">
32
- <el-form
33
- ref="manual"
34
- label-position="left"
35
- :model="manualInfo"
36
- label-width="100px">
37
- <el-form-item
38
- :label="$t('openatccomponents.overview.patternoffset') + ':'"
39
- prop="count">
40
- <el-input-number :placeholder="$t('openatccomponents.common.input')" :min="0" :max="65535" :precision="0" :step="1" :controls="false" v-model.number="manualInfo.offset" size="mini"></el-input-number>
41
- <!-- <el-input v-model="manualInfo.offset" size="mini" :placeholder="$t('openatccomponents.common.input')"></el-input> -->
42
- </el-form-item>
43
- <el-form-item
44
- :label="$t('openatccomponents.overview.duration') + ':'"
45
- prop="intersection">
46
- <el-input-number :placeholder="$t('openatccomponents.common.input')" :min="0" :max="65535" :precision="0" :step="1" :controls="false" v-model.number="manualInfo.duration" size="mini"></el-input-number>
47
- <!-- <el-input v-model="manualInfo.duration" size="mini" :placeholder="$t('openatccomponents.common.input')"></el-input> -->
48
- </el-form-item>
49
- </el-form>
50
- </el-col>
51
- </el-row>
52
- <el-row>
53
- <div class="title" style="margin-top:18px; margin-bottom:10px">{{$t('openatccomponents.overview.patternstate')}}:
54
- <span>({{$t('openatccomponents.overview.cycle')}}: {{cycle}} {{$t('openatccomponents.overview.patternoffset')}}: {{offset}})</span>
55
- </div>
56
- <stage-status
57
- :patternStatusList="patternOne.length===0?planPattern.rings:patternOne[0].rings"
58
- >
59
- </stage-status>
60
- <pattern-list
61
- :patternList="patternOne.length===0?planPattern.rings:patternOne"
62
- :patternStatusList="patternOne.length===0?planPattern.rings:patternOne[0].rings"
63
- :cycles="patternOne.length===0?planPattern.cycle:patternOne[0].cycle"
64
- :phaseList="phaseList">
65
- </pattern-list>
66
- </el-row>
67
- <el-row>
68
- <el-tabs v-model="activeList" type="card">
69
- <el-tab-pane :label="$t('openatccomponents.pattern.ringConfig')" name="ring">
70
- <!-- <el-row :gutter="20"> -->
71
- <!-- <el-col :span="12" > -->
72
- <!-- <div class="components-container board" > -->
73
- <div style="width: 100%; overflow: hidden;margin-top: 20px;">
74
- <kan-ban v-for="n in ringCount"
75
- :key="n" class="closephasekanban"
76
- :index="n"
77
- :options="patternOne.length===0?allPatternList[0].options:patternOne[0].options"
78
- :list="patternOne.length===0?planPattern.rings[n-1]:patternOne[0].rings[n-1]"
79
- :phaseList="phaseList"
80
- :header-text="$t('openatccomponents.pattern.ring')+n"
81
- @handleSplit="handleSplit">
82
- </kan-ban>
83
- </div>
84
- <!-- </el-col> -->
85
- <!-- </el-row> -->
86
- </el-tab-pane>
87
- <el-tab-pane :label="$t('openatccomponents.pattern.stageConfig')" name="kanban">
88
- <el-scrollbar :vertical="true">
89
- <div class="stage-panel-contener">
90
- <stage-board v-for="(stage,index) in patternOne.length===0?allPatternList[0].stagesList:patternOne[0].stagesList"
91
- class="closephasekanban"
92
- :key="index"
93
- :stage="stage"
94
- :options="patternOne.length===0?allPatternList[0].options:patternOne[0].options"
95
- :stageInfo="patternOne.length===0?allPatternList[0].stagesList:patternOne[0].stagesList"
96
- :coordphaseOption="coordphaseOption"
97
- :subIndex="index"
98
- @onStageSplitChange="onStageSplitChange"
99
- @stageSplitChange="stageSplitChange"
100
- @onStageDelaystartChange="onStageDelaystartChange"
101
- @onStageAdvanceendChange="onStageAdvanceendChange"
102
- >
103
- </stage-board>
104
- </div>
105
- </el-scrollbar>
106
- </el-tab-pane>
107
- <el-tab-pane :label="$t('openatccomponents.pattern.parameters')" name="parame">
108
- <el-row>
109
- <!-- <el-col :span="12"> -->
110
- <expend-config
111
- v-for="(j,index) in ringCounts"
112
- :key="index"
113
- class="closephasekanban"
114
- :options="patternOne.length===0?allPatternList[0].options:patternOne[0].options"
115
- :header-text="$t('openatccomponents.pattern.ring')+j"
116
- :list="patternOne.length===0?planPattern.rings[j-1]:patternOne[0].rings[j-1]"
117
- >
118
- </expend-config>
119
- <!-- </el-col> -->
120
- <!-- <el-col :span="12"> -->
121
- <div style="width: 60%;margin: 10px auto;color:#ffffff">
122
- {{$t('openatccomponents.pattern.forbiddenstage')}}
123
- <el-input class="stage-value" size="small" v-model="forbiddenstage"></el-input>
124
- </div>
125
- <div style="width: 60%;margin: 10px auto;color:#ffffff">
126
- {{$t('openatccomponents.pattern.screenstage')}}
127
- <el-input class="stage-value" size="small" v-model="screenstage"></el-input>
128
- </div>
129
- <div style="width: 60%;margin: 10px auto;color:#ffffff">
130
- <!-- <el-col :span="8"> -->
131
- {{$t('openatccomponents.pattern.coordinatestage')}}
132
- <el-input class="stage-value" size="small" v-model="coordinatestage"></el-input>
133
- <!-- </el-col> -->
134
- </div>
135
- <!-- </el-col> -->
136
- </el-row>
137
- </el-tab-pane>
138
- <el-tab-pane :label="$t('openatccomponents.pattern.overLap')" name="overlap">
139
- <el-row :gutter="20">
140
- <el-col :span="24" >
141
- <over-lap
142
- :stageList="stagesList"
143
- :overlap="overlap"
144
- :checked="true"
145
- :tentative="true"
146
- :cycle="patternOne.length===0?planPattern.cycle:patternOne[0].cycle"
147
- >
148
- </over-lap>
149
- </el-col>
150
- </el-row>
151
- </el-tab-pane>
152
- </el-tabs>
153
- </el-row>
154
- <div class="footer" v-if="realtimeStatusModalvisible">
155
- <el-button @click="handleClose()">{{$t('openatccomponents.button.Back')}}</el-button>
156
- <el-button type="primary" @click="handleManualControl()">{{$t('openatccomponents.overview.implement')}}</el-button>
157
- </div>
158
- <div class="footer" v-if="!realtimeStatusModalvisible">
159
- <el-button @click="handleClose()">{{$t('openatccomponents.button.Back')}}</el-button>
160
- <el-button type="primary" @click="handleManualControl()">{{$t('openatccomponents.overview.comfirm')}}</el-button>
161
- </div>
162
- </div>
163
- </template>
164
-
165
- <script>
166
- export default {
167
- name: 'tentativeplancontrol',
168
- props: {
169
- realtimeStatusModalvisible: {
170
- type: Boolean,
171
- default: true
172
- },
173
- controlData: {
174
- type: Object
175
- },
176
- phaseList: {
177
- type: Array
178
- },
179
- overlap: {
180
- type: Array
181
- },
182
- allPatternList: {
183
- type: Array
184
- },
185
- patternSelect: {
186
- type: Array
187
- }
188
- },
189
- computed: {
190
- rings () {
191
- return this.patternOne.length === 0 ? this.planPattern.rings : this.patternOne[0].rings
192
- },
193
- cycle () {
194
- return this.patternOne.length === 0 ? this.max : (this.patternOne.length > 0 && (this.patternOne[0].cycle < this.max)) ? this.max : this.patternOne[0].cycle
195
- },
196
- offset () {
197
- return Number((this.patternOne.length === 0 || this.manualInfo.offset > 0) ? this.manualInfo.offset : this.patternOne[0].offset)
198
- },
199
- forbiddenstage () {
200
- return this.patternOne.length === 0 ? this.allPatternList[0].forbiddenstage : this.patternOne[0].forbiddenstage
201
- },
202
- screenstage () {
203
- return this.patternOne.length === 0 ? this.allPatternList[0].screenstage : this.patternOne[0].screenstage
204
- },
205
- coordinatestage () {
206
- return this.patternOne.length === 0 ? this.allPatternList[0].coordinatestage : this.patternOne[0].coordinatestage
207
- }
208
- },
209
- data () {
210
- return {
211
- stagesList: [],
212
- phaseRings: [],
213
- options: {
214
- group: 'pattern'
215
- },
216
- // overlap: [
217
- // {
218
- // 'id': 1,
219
- // 'desc': '东方向南半测行人相位',
220
- // 'includedphases': [
221
- // 1,
222
- // 8
223
- // ],
224
- // 'peddirection': [
225
- // 6
226
- // ]
227
- // },
228
- // {
229
- // 'id': 2,
230
- // 'desc': '东方向北半测行人相位',
231
- // 'includedphases': [
232
- // 1,
233
- // 2
234
- // ],
235
- // 'peddirection': [
236
- // 5
237
- // ]
238
- // },
239
- // {
240
- // 'id': 3,
241
- // 'desc': '西方向南半测行人相位',
242
- // 'includedphases': [
243
- // 5,
244
- // 6
245
- // ],
246
- // 'peddirection': [
247
- // 8
248
- // ]
249
- // },
250
- // {
251
- // 'id': 4,
252
- // 'desc': '西方向北半测行人相位',
253
- // 'includedphases': [
254
- // 4,
255
- // 5
256
- // ],
257
- // 'peddirection': [
258
- // 7
259
- // ]
260
- // },
261
- // {
262
- // 'id': 5,
263
- // 'desc': '南方向东半测行人相位',
264
- // 'includedphases': [
265
- // 7,
266
- // 8
267
- // ],
268
- // 'peddirection': [
269
- // 10
270
- // ]
271
- // },
272
- // {
273
- // 'id': 6,
274
- // 'desc': '南方向西半测行人相位',
275
- // 'includedphases': [
276
- // 6,
277
- // 7
278
- // ],
279
- // 'peddirection': [
280
- // 9
281
- // ]
282
- // },
283
- // {
284
- // 'id': 7,
285
- // 'desc': '北方向东半测行人相位',
286
- // 'includedphases': [
287
- // 2,
288
- // 3
289
- // ],
290
- // 'peddirection': [
291
- // 12
292
- // ]
293
- // },
294
- // {
295
- // 'id': 8,
296
- // 'desc': '北方向西半测行人相位',
297
- // 'includedphases': [
298
- // 3,
299
- // 4
300
- // ],
301
- // 'peddirection': [
302
- // 11
303
- // ]
304
- // }
305
- // ],
306
- max: '',
307
- patternCycleEqual: true,
308
- activeList: 'ring',
309
- ringCount: 1,
310
- ringCounts: 1,
311
- coordphaseOption: [],
312
- patternOne: [],
313
- planPattern: {},
314
- // allPatternList: [
315
- // {
316
- // 'id': 1,
317
- // 'desc': '',
318
- // 'offset': 10,
319
- // 'cycle': 120,
320
- // 'rings': [
321
- // [
322
- // {
323
- // 'name': 'phase1',
324
- // 'id': 1,
325
- // 'value': 30,
326
- // 'mode': 2,
327
- // 'options': [],
328
- // 'minSplit': 20,
329
- // 'desc': [
330
- // {
331
- // 'id': 13,
332
- // 'color': '#454545'
333
- // }
334
- // ]
335
- // },
336
- // {
337
- // 'name': 'phase2',
338
- // 'id': 2,
339
- // 'value': 30,
340
- // 'mode': 2,
341
- // 'options': [],
342
- // 'minSplit': 20,
343
- // 'desc': [
344
- // {
345
- // 'id': 10,
346
- // 'color': '#454545'
347
- // },
348
- // {
349
- // 'id': 12,
350
- // 'color': '#454545'
351
- // }
352
- // ]
353
- // },
354
- // {
355
- // 'name': 'phase3',
356
- // 'id': 3,
357
- // 'value': 30,
358
- // 'mode': 2,
359
- // 'options': [],
360
- // 'minSplit': 20,
361
- // 'desc': [
362
- // {
363
- // 'id': 1,
364
- // 'color': '#454545'
365
- // }
366
- // ]
367
- // },
368
- // {
369
- // 'name': 'phase4',
370
- // 'id': 4,
371
- // 'value': 30,
372
- // 'mode': 2,
373
- // 'options': [],
374
- // 'minSplit': 20,
375
- // 'desc': [
376
- // {
377
- // 'id': 6,
378
- // 'color': '#454545'
379
- // },
380
- // {
381
- // 'id': 8,
382
- // 'color': '#454545'
383
- // }
384
- // ]
385
- // }
386
- // ],
387
- // [
388
- // {
389
- // 'name': 'phase5',
390
- // 'id': 5,
391
- // 'value': 30,
392
- // 'mode': 2,
393
- // 'options': [],
394
- // 'minSplit': 20,
395
- // 'desc': [
396
- // {
397
- // 'id': 9,
398
- // 'color': '#454545'
399
- // }
400
- // ]
401
- // },
402
- // {
403
- // 'name': 'phase6',
404
- // 'id': 6,
405
- // 'value': 30,
406
- // 'mode': 2,
407
- // 'options': [],
408
- // 'minSplit': 20,
409
- // 'desc': [
410
- // {
411
- // 'id': 14,
412
- // 'color': '#454545'
413
- // },
414
- // {
415
- // 'id': 16,
416
- // 'color': '#454545'
417
- // }
418
- // ]
419
- // },
420
- // {
421
- // 'name': 'phase7',
422
- // 'id': 7,
423
- // 'value': 30,
424
- // 'mode': 2,
425
- // 'options': [],
426
- // 'minSplit': 20,
427
- // 'desc': [
428
- // {
429
- // 'id': 5,
430
- // 'color': '#454545'
431
- // }
432
- // ]
433
- // },
434
- // {
435
- // 'name': 'phase8',
436
- // 'id': 8,
437
- // 'value': 30,
438
- // 'mode': 2,
439
- // 'options': [],
440
- // 'minSplit': 20,
441
- // 'desc': [
442
- // {
443
- // 'id': 2,
444
- // 'color': '#454545'
445
- // },
446
- // {
447
- // 'id': 4,
448
- // 'color': '#454545'
449
- // }
450
- // ]
451
- // }
452
- // ],
453
- // [],
454
- // []
455
- // ],
456
- // 'barriers': [
457
- // {
458
- // 'barrier': 1,
459
- // 'length': 60,
460
- // 'items': [
461
- // {
462
- // 'ring': 2,
463
- // 'data': [
464
- // 5,
465
- // 6
466
- // ]
467
- // },
468
- // {
469
- // 'ring': 1,
470
- // 'data': [
471
- // 1,
472
- // 2
473
- // ]
474
- // }
475
- // ]
476
- // },
477
- // {
478
- // 'barrier': 2,
479
- // 'length': 60,
480
- // 'items': [
481
- // {
482
- // 'ring': 2,
483
- // 'data': [
484
- // 7,
485
- // 8
486
- // ]
487
- // },
488
- // {
489
- // 'ring': 1,
490
- // 'data': [
491
- // 3,
492
- // 4
493
- // ]
494
- // }
495
- // ]
496
- // }
497
- // ],
498
- // 'stagesList': [
499
- // {
500
- // 'split': 30,
501
- // 'stages': [
502
- // 1,
503
- // 5
504
- // ]
505
- // },
506
- // {
507
- // 'split': 30,
508
- // 'stages': [
509
- // 2,
510
- // 6
511
- // ]
512
- // },
513
- // {
514
- // 'split': 30,
515
- // 'stages': [
516
- // 3,
517
- // 7
518
- // ]
519
- // },
520
- // {
521
- // 'split': 30,
522
- // 'stages': [
523
- // 4,
524
- // 8
525
- // ]
526
- // }
527
- // ],
528
- // 'stages': [
529
- // [
530
- // 1,
531
- // 5
532
- // ],
533
- // [
534
- // 2,
535
- // 6
536
- // ],
537
- // [
538
- // 3,
539
- // 7
540
- // ],
541
- // [
542
- // 4,
543
- // 8
544
- // ]
545
- // ]
546
- // },
547
- // {
548
- // 'id': 2,
549
- // 'desc': '方案2',
550
- // 'offset': 0,
551
- // 'cycle': 110,
552
- // 'rings': [
553
- // [
554
- // {
555
- // 'name': 'phase1',
556
- // 'id': 1,
557
- // 'value': 20,
558
- // 'mode': 2,
559
- // 'options': [
560
- // 0,
561
- // 0,
562
- // 0
563
- // ],
564
- // 'minSplit': 13,
565
- // 'delaystart': 0,
566
- // 'advanceend': 0
567
- // },
568
- // {
569
- // 'name': 'phase2',
570
- // 'id': 2,
571
- // 'value': 35,
572
- // 'mode': 2,
573
- // 'options': [
574
- // 0,
575
- // 0,
576
- // 0
577
- // ],
578
- // 'minSplit': 13,
579
- // 'delaystart': 0,
580
- // 'advanceend': 0
581
- // },
582
- // {
583
- // 'name': 'phase3',
584
- // 'id': 3,
585
- // 'value': 30,
586
- // 'mode': 2,
587
- // 'options': [
588
- // 0,
589
- // 0,
590
- // 0
591
- // ],
592
- // 'minSplit': 13,
593
- // 'delaystart': 0,
594
- // 'advanceend': 0
595
- // },
596
- // {
597
- // 'name': 'phase4',
598
- // 'id': 4,
599
- // 'value': 25,
600
- // 'mode': 2,
601
- // 'options': [
602
- // 0,
603
- // 0,
604
- // 0
605
- // ],
606
- // 'minSplit': 13,
607
- // 'delaystart': 0,
608
- // 'advanceend': 0
609
- // }
610
- // ],
611
- // [
612
- // {
613
- // 'name': 'Phase 5',
614
- // 'id': 5,
615
- // 'value': 27,
616
- // 'mode': 2,
617
- // 'options': [
618
- // 0,
619
- // 0,
620
- // 0
621
- // ],
622
- // 'minSplit': 13,
623
- // 'delaystart': 0,
624
- // 'advanceend': 0
625
- // },
626
- // {
627
- // 'name': 'Phase 6',
628
- // 'id': 6,
629
- // 'value': 28,
630
- // 'mode': 2,
631
- // 'options': [
632
- // 0,
633
- // 0,
634
- // 0
635
- // ],
636
- // 'minSplit': 13,
637
- // 'delaystart': 0,
638
- // 'advanceend': 0
639
- // },
640
- // {
641
- // 'name': 'Phase 7',
642
- // 'id': 7,
643
- // 'value': 35,
644
- // 'mode': 2,
645
- // 'options': [
646
- // 0,
647
- // 0,
648
- // 0
649
- // ],
650
- // 'minSplit': 13,
651
- // 'delaystart': 0,
652
- // 'advanceend': 0
653
- // },
654
- // {
655
- // 'name': 'Phase 8',
656
- // 'id': 8,
657
- // 'value': 20,
658
- // 'mode': 2,
659
- // 'options': [
660
- // 0,
661
- // 0,
662
- // 0
663
- // ],
664
- // 'minSplit': 13,
665
- // 'delaystart': 0,
666
- // 'advanceend': 0
667
- // }
668
- // ],
669
- // [],
670
- // []
671
- // ],
672
- // 'stagesList': [
673
- // {
674
- // 'split': 20,
675
- // 'stages': [
676
- // 1,
677
- // 5
678
- // ],
679
- // 'delaystart': 0,
680
- // 'advanceend': 0
681
- // },
682
- // {
683
- // 'split': 7,
684
- // 'stages': [
685
- // 2,
686
- // 5
687
- // ],
688
- // 'delaystart': 0,
689
- // 'advanceend': 0
690
- // },
691
- // {
692
- // 'split': 28,
693
- // 'stages': [
694
- // 2,
695
- // 6
696
- // ],
697
- // 'delaystart': 0,
698
- // 'advanceend': 0
699
- // },
700
- // {
701
- // 'split': 30,
702
- // 'stages': [
703
- // 3,
704
- // 7
705
- // ],
706
- // 'delaystart': 0,
707
- // 'advanceend': 0
708
- // },
709
- // {
710
- // 'split': 5,
711
- // 'stages': [
712
- // 4,
713
- // 7
714
- // ],
715
- // 'delaystart': 0,
716
- // 'advanceend': 0
717
- // },
718
- // {
719
- // 'split': 20,
720
- // 'stages': [
721
- // 4,
722
- // 8
723
- // ],
724
- // 'delaystart': 0,
725
- // 'advanceend': 0
726
- // }
727
- // ],
728
- // 'stages': [
729
- // [
730
- // 1,
731
- // 5
732
- // ],
733
- // [
734
- // 2,
735
- // 5
736
- // ],
737
- // [
738
- // 2,
739
- // 6
740
- // ],
741
- // [
742
- // 3,
743
- // 7
744
- // ],
745
- // [
746
- // 4,
747
- // 7
748
- // ],
749
- // [
750
- // 4,
751
- // 8
752
- // ]
753
- // ],
754
- // 'barriers': [
755
- // {
756
- // 'barrier': 1,
757
- // 'length': 55,
758
- // 'items': [
759
- // {
760
- // 'ring': 2,
761
- // 'data': [
762
- // 5,
763
- // 6
764
- // ]
765
- // },
766
- // {
767
- // 'ring': 1,
768
- // 'data': [
769
- // 1,
770
- // 2
771
- // ]
772
- // }
773
- // ]
774
- // },
775
- // {
776
- // 'barrier': 2,
777
- // 'length': 55,
778
- // 'items': [
779
- // {
780
- // 'ring': 2,
781
- // 'data': [
782
- // 7,
783
- // 8
784
- // ]
785
- // },
786
- // {
787
- // 'ring': 1,
788
- // 'data': [
789
- // 3,
790
- // 4
791
- // ]
792
- // }
793
- // ]
794
- // }
795
- // ]
796
- // },
797
- // {
798
- // 'id': 3,
799
- // 'desc': '方案3',
800
- // 'offset': 0,
801
- // 'cycle': 120,
802
- // 'rings': [
803
- // [
804
- // {
805
- // 'name': 'phase1',
806
- // 'id': 1,
807
- // 'value': 40,
808
- // 'mode': 2,
809
- // 'options': [
810
- // 0,
811
- // 0,
812
- // 0
813
- // ],
814
- // 'minSplit': 13,
815
- // 'delaystart': 0,
816
- // 'advanceend': 0
817
- // },
818
- // {
819
- // 'name': 'phase2',
820
- // 'id': 2,
821
- // 'value': 20,
822
- // 'mode': 2,
823
- // 'options': [
824
- // 0,
825
- // 0,
826
- // 0
827
- // ],
828
- // 'minSplit': 13,
829
- // 'delaystart': 0,
830
- // 'advanceend': 0
831
- // },
832
- // {
833
- // 'name': 'phase3',
834
- // 'id': 3,
835
- // 'value': 30,
836
- // 'mode': 2,
837
- // 'options': [
838
- // 0,
839
- // 0,
840
- // 0
841
- // ],
842
- // 'minSplit': 13,
843
- // 'delaystart': 0,
844
- // 'advanceend': 0
845
- // },
846
- // {
847
- // 'name': 'phase4',
848
- // 'id': 4,
849
- // 'value': 30,
850
- // 'mode': 2,
851
- // 'options': [
852
- // 0,
853
- // 0,
854
- // 0
855
- // ],
856
- // 'minSplit': 13,
857
- // 'delaystart': 0,
858
- // 'advanceend': 0
859
- // }
860
- // ],
861
- // [
862
- // {
863
- // 'name': 'Phase 5',
864
- // 'id': 5,
865
- // 'value': 20,
866
- // 'mode': 2,
867
- // 'options': [
868
- // 0,
869
- // 0,
870
- // 0
871
- // ],
872
- // 'minSplit': 13,
873
- // 'delaystart': 0,
874
- // 'advanceend': 0
875
- // },
876
- // {
877
- // 'name': 'Phase 6',
878
- // 'id': 6,
879
- // 'value': 40,
880
- // 'mode': 2,
881
- // 'options': [
882
- // 0,
883
- // 0,
884
- // 0
885
- // ],
886
- // 'minSplit': 13,
887
- // 'delaystart': 0,
888
- // 'advanceend': 0
889
- // },
890
- // {
891
- // 'name': 'Phase 7',
892
- // 'id': 7,
893
- // 'value': 30,
894
- // 'mode': 2,
895
- // 'options': [
896
- // 0,
897
- // 0,
898
- // 0
899
- // ],
900
- // 'minSplit': 13,
901
- // 'delaystart': 0,
902
- // 'advanceend': 0
903
- // },
904
- // {
905
- // 'name': 'Phase 8',
906
- // 'id': 8,
907
- // 'value': 30,
908
- // 'mode': 2,
909
- // 'options': [
910
- // 0,
911
- // 0,
912
- // 0
913
- // ],
914
- // 'minSplit': 13,
915
- // 'delaystart': 0,
916
- // 'advanceend': 0
917
- // }
918
- // ],
919
- // [],
920
- // []
921
- // ],
922
- // 'stagesList': [
923
- // {
924
- // 'split': 20,
925
- // 'stages': [
926
- // 1,
927
- // 5
928
- // ],
929
- // 'delaystart': 0,
930
- // 'advanceend': 0
931
- // },
932
- // {
933
- // 'split': 20,
934
- // 'stages': [
935
- // 1,
936
- // 6
937
- // ],
938
- // 'delaystart': 0,
939
- // 'advanceend': 0
940
- // },
941
- // {
942
- // 'split': 20,
943
- // 'stages': [
944
- // 2,
945
- // 6
946
- // ],
947
- // 'delaystart': 0,
948
- // 'advanceend': 0
949
- // },
950
- // {
951
- // 'split': 30,
952
- // 'stages': [
953
- // 3,
954
- // 7
955
- // ],
956
- // 'delaystart': 0,
957
- // 'advanceend': 0
958
- // },
959
- // {
960
- // 'split': 30,
961
- // 'stages': [
962
- // 4,
963
- // 8
964
- // ],
965
- // 'delaystart': 0,
966
- // 'advanceend': 0
967
- // }
968
- // ],
969
- // 'stages': [
970
- // [
971
- // 1,
972
- // 5
973
- // ],
974
- // [
975
- // 1,
976
- // 6
977
- // ],
978
- // [
979
- // 2,
980
- // 6
981
- // ],
982
- // [
983
- // 3,
984
- // 7
985
- // ],
986
- // [
987
- // 4,
988
- // 8
989
- // ]
990
- // ],
991
- // 'barriers': [
992
- // {
993
- // 'barrier': 1,
994
- // 'length': 60,
995
- // 'items': [
996
- // {
997
- // 'ring': 2,
998
- // 'data': [
999
- // 5,
1000
- // 6
1001
- // ]
1002
- // },
1003
- // {
1004
- // 'ring': 1,
1005
- // 'data': [
1006
- // 1,
1007
- // 2
1008
- // ]
1009
- // }
1010
- // ]
1011
- // },
1012
- // {
1013
- // 'barrier': 2,
1014
- // 'length': 60,
1015
- // 'items': [
1016
- // {
1017
- // 'ring': 2,
1018
- // 'data': [
1019
- // 7,
1020
- // 8
1021
- // ]
1022
- // },
1023
- // {
1024
- // 'ring': 1,
1025
- // 'data': [
1026
- // 3,
1027
- // 4
1028
- // ]
1029
- // }
1030
- // ]
1031
- // }
1032
- // ]
1033
- // }
1034
- // ],
1035
- manualInfo: {
1036
- tempPatternid: '',
1037
- offset: 0,
1038
- duration: 300,
1039
- tempDelay: 0 // 控制方式手动操作的情况下的延迟时间的临时值。
1040
- // tempDuration: 300 // 控制方式手动操作的情况下的持续时间的临时值。
1041
- }
1042
- }
1043
- },
1044
- created () {
1045
- this.patternPlan()
1046
- this.getCycle()
1047
- if (this.patternOne.length === 0) {
1048
- this.handleStageData(this.planPattern.rings)
1049
- }
1050
- this.initData()
1051
- },
1052
- methods: {
1053
- patternPlan () {
1054
- let Pattern = {
1055
- offset: 0,
1056
- cycle: 0,
1057
- rings: [[], [], [], []]
1058
- }
1059
- var newPattern = JSON.parse(JSON.stringify(Pattern))
1060
- for (let phase of this.phaseList) {
1061
- let ring = {}
1062
- ring.name = 'Phase ' + phase.id
1063
- ring.desc = this.getPhaseDescription(phase.direction)
1064
- ring.id = phase.id
1065
- ring.value = 30
1066
- ring.mode = 2
1067
- ring.options = []
1068
- ring.delaystart = 0
1069
- ring.advanceend = 0
1070
- if (phase.ring === 1) {
1071
- newPattern.rings[0].push(ring)
1072
- } else if (phase.ring === 2) {
1073
- newPattern.rings[1].push(ring)
1074
- } else if (phase.ring === 3) {
1075
- newPattern.rings[2].push(ring)
1076
- } else if (phase.ring === 4) {
1077
- newPattern.rings[3].push(ring)
1078
- }
1079
- }
1080
- this.planPattern = newPattern
1081
- },
1082
- getCycle () {
1083
- for (let rings of this.planPattern.rings) {
1084
- let num = 0
1085
- for (let i = 0; i < rings.length; i++) {
1086
- if (rings[i].length !== 0) {
1087
- if (rings[i].mode === 7) { // 忽略相位不计周期
1088
- continue
1089
- }
1090
- num = num + Number(rings[i].value)
1091
- }
1092
- }
1093
- if (num !== 0) {
1094
- this.planPattern.cycle = num
1095
- break
1096
- }
1097
- }
1098
- },
1099
- getPhaseDescription (phaseList) {
1100
- if (!phaseList) return
1101
- let list = []
1102
- for (let id of phaseList) {
1103
- let obj = {}
1104
- obj.id = id
1105
- obj.color = '#454545'
1106
- list.push(obj)
1107
- }
1108
- return list
1109
- },
1110
- handleClose () {
1111
- this.$emit('closePhaseBack')
1112
- },
1113
- onStageSplitChange (diff, rowIndex, subIndex) {
1114
- let stageArr = this.stagesList[subIndex].stages
1115
- let row = this.patternList[rowIndex]
1116
- let ringsList = row.rings
1117
- for (let rings of ringsList) {
1118
- for (let ring of rings) {
1119
- if (stageArr.includes(ring.id)) {
1120
- ring.value = (ring.value ? ring.value : 0) + diff
1121
- continue
1122
- }
1123
- }
1124
- }
1125
- },
1126
- stageSplitChange (diff, rowIndex, subIndex) {
1127
- let row = this.patternList[rowIndex]
1128
- let ringsList = row.stagesList
1129
- for (let rings of ringsList) {
1130
- if (subIndex === rings.key) {
1131
- rings.stageSplit = (rings.green ? rings.green : 0) + (rings.yellow ? rings.yellow : 0) + (rings.red ? rings.red : 0)
1132
- continue
1133
- }
1134
- }
1135
- },
1136
- onStageDelaystartChange (diff, rowIndex, subIndex) {
1137
- let stageArr = this.stagesList[subIndex].stages
1138
- let row = this.patternList[rowIndex]
1139
- let ringsList = row.rings
1140
- for (let rings of ringsList) {
1141
- for (let ring of rings) {
1142
- if (stageArr.includes(ring.id)) {
1143
- ring.delaystart = (ring.delaystart ? ring.delaystart : 0) + diff
1144
- continue
1145
- }
1146
- }
1147
- }
1148
- },
1149
- onStageAdvanceendChange (diff, rowIndex, subIndex) {
1150
- let stageArr = this.stagesList[subIndex].stages
1151
- let row = this.patternList[rowIndex]
1152
- let ringsList = row.rings
1153
- for (let rings of ringsList) {
1154
- for (let ring of rings) {
1155
- if (stageArr.includes(ring.id)) {
1156
- ring.advanceend = (ring.advanceend ? ring.advanceend : 0) + diff
1157
- continue
1158
- }
1159
- }
1160
- }
1161
- },
1162
- handleSplit (index) {
1163
- if (this.patternOne.length > 0) {
1164
- let currPattern = this.patternOne[0].rings
1165
- setTimeout(() => {
1166
- this.handleStageData(currPattern)
1167
- }, 50)
1168
- } else {
1169
- let currPattern = this.planPattern.rings
1170
- setTimeout(() => {
1171
- this.handleStageData(currPattern)
1172
- }, 50)
1173
- }
1174
- },
1175
- selectPattern () {
1176
- this.manualInfo.offset = 0
1177
- let selectId = isNaN(parseInt(this.manualInfo.tempPatternid)) ? Number(this.manualInfo.tempPatternid.replace(/[^0-9]/ig, '')) : this.manualInfo.tempPatternid
1178
- this.patternOne = this.allPatternList.filter(item => {
1179
- return item.id === selectId
1180
- })
1181
- this.manualInfo.offset = this.offset
1182
- for (let rings of this.patternOne[0].rings) {
1183
- if (rings.length === 0) continue
1184
- for (let ring of rings) {
1185
- if (ring.value === 0) continue
1186
- let currPhase = this.phaseList.filter((item) => {
1187
- return item.id === ring.id
1188
- })[0]
1189
- ring.desc = currPhase.direction.map(item => {
1190
- return {
1191
- id: item,
1192
- color: '#454545'
1193
- }
1194
- })
1195
- }
1196
- }
1197
- this.handleStageData(this.patternOne[0].rings)
1198
- },
1199
- handleStageData (rings) { // stagesList
1200
- for (let i = 0; i < rings.length; i++) {
1201
- if (rings[i].length > 0) {
1202
- let phaseList = []
1203
- let stagesList = []
1204
- // rings = JSON.parse(JSON.stringify(rings))
1205
- let mapAdd = rings.map(item => {
1206
- return item.map(val => {
1207
- return val.value + (val.sum ? val.sum : 0)
1208
- })
1209
- })
1210
- let maxCycle = mapAdd.length > 0 ? mapAdd.map(item => {
1211
- return item.length > 0 ? item.reduce((a, b) => {
1212
- return a + b
1213
- }) : 0
1214
- }) : 0
1215
- this.max = Math.max(...maxCycle)// 每个环的周期最大值
1216
- this.stateList = [0]
1217
- this.narr = []
1218
- let currentIds = ''
1219
- let lastCurrentIds = ''
1220
- for (let j = 0; j <= this.max; j++) { // 指针长度
1221
- for (let i = 0; i < rings.length; i++) { // 环列表
1222
- let ring = rings[i]// 每个环对象
1223
- let sum = 0
1224
- for (let n = 0; n < ring.length; n++) { // 相位累计长度
1225
- if (ring[n].mode !== 7) {
1226
- sum = sum + ring[n].value + (ring[n].sum ? ring[n].sum : 0)
1227
- if (j < sum) {
1228
- let phaseId = ring[n].id
1229
- currentIds = currentIds + '-' + phaseId
1230
- break
1231
- }
1232
- }
1233
- }
1234
- }
1235
- if (lastCurrentIds !== currentIds && lastCurrentIds !== '') { // 当前相位id和上一个相比不同说明相位变化了
1236
- phaseList.push(lastCurrentIds)
1237
- this.stateList.push(j)// 阶段累计长度的集合
1238
- }
1239
- lastCurrentIds = currentIds
1240
- currentIds = ''
1241
- }
1242
- let newPhaselist = []
1243
- phaseList.forEach(i => {
1244
- let rangeArr = i.split('-').map(Number)
1245
- if (rangeArr.length > 2) {
1246
- newPhaselist.push([
1247
- JSON.parse(JSON.stringify(rangeArr[1])),
1248
- JSON.parse(JSON.stringify(rangeArr[2]))
1249
- ])
1250
- } else {
1251
- newPhaselist.push([
1252
- JSON.parse(JSON.stringify(rangeArr[1]))
1253
- ])
1254
- }
1255
- })
1256
- for (let i = this.stateList.length - 1; i >= 1; i--) {
1257
- this.narr.push(this.stateList[i] - this.stateList[i - 1])
1258
- }
1259
- // newPhaselist
1260
- this.narr.reverse()// 阶段差
1261
- for (let i = 0; i < newPhaselist.length; i++) {
1262
- let stage = JSON.parse(JSON.stringify(newPhaselist[i]))
1263
- let stageItem = this.getStageItem(stage, rings, i)
1264
- stagesList.push(JSON.parse(JSON.stringify(stageItem)))
1265
- }
1266
- this.stagesList = JSON.parse(JSON.stringify(stagesList))
1267
- }
1268
- }
1269
- },
1270
- getStageItem (stageArr, ringsList, i) {
1271
- let res = {
1272
- key: i,
1273
- split: this.narr[i], // 阶段绿性比
1274
- stages: stageArr,
1275
- delaystart: 0,
1276
- advanceend: 0
1277
- }
1278
- // let splitArr = []
1279
- let delaystartArr = []
1280
- let advanceendArr = []
1281
- for (let rings of ringsList) {
1282
- for (let ring of rings) {
1283
- if (stageArr.includes(ring.id)) {
1284
- // let split = ring.value
1285
- let delaystart = ring.delaystart
1286
- let advanceend = ring.advanceend
1287
- // splitArr.push(split)
1288
- delaystartArr.push(delaystart)
1289
- advanceendArr.push(advanceend)
1290
- }
1291
- }
1292
- }
1293
- // splitArr.sort(function (a, b) { return a - b })
1294
- delaystartArr.sort(function (a, b) { return b - a })
1295
- advanceendArr.sort(function (a, b) { return a - b })
1296
- // res.split = splitArr.length > 0 ? splitArr[0] : 0
1297
- res.delaystart = delaystartArr.length > 0 ? delaystartArr[0] : 0
1298
- res.advanceend = advanceendArr.length > 0 ? advanceendArr[0] : 0
1299
- return res
1300
- },
1301
- initData () {
1302
- // 判断有几个环,就创建几个看板
1303
- // let phaseList = this.globalParamModel.getParamsByType('phaseList')
1304
- this.coordphaseOption = this.phaseList.map(ele => {
1305
- return {
1306
- value: ele.id
1307
- }
1308
- })
1309
- // this.overlap = this.globalParamModel.getParamsByType('overlaplList')
1310
- // this.agentId = getIframdevid()
1311
- let rings = []
1312
- if (this.phaseList.length === 0) {
1313
- // this.$store.getters.tscParam.patternList = []
1314
- return
1315
- }
1316
- for (let phase of this.phaseList) {
1317
- rings.push(phase.ring)
1318
- }
1319
- this.ringCount = Array.from(new Set(rings)) // 去除数组重复的元素
1320
- this.ringCount = this.ringCount.sort(this.sortNumbers) // 把数组中的值按照从小到大的顺序重新排序
1321
- this.ringCounts = Array.from(new Set(rings)) // 去除数组重复的元素
1322
- this.ringCounts = this.ringCounts.sort(this.sortNumbers) // 把数组中的值按照从小到大的顺序重新排序
1323
- // this.increaseId()
1324
- // this.getCycle()
1325
- // this.updatePhaseDescription()
1326
- // this.getOptionsOfRing()
1327
- },
1328
- sortNumbers (a, b) {
1329
- return a - b
1330
- },
1331
- isRingCycleEqual (rings) {
1332
- let isequal = true
1333
- // this.patternmsg = []
1334
- let maxCycle = 0
1335
- for (let ring of rings) {
1336
- if (ring.length === 0) continue
1337
- let cycle = 0
1338
- for (let r of ring) {
1339
- if (r.mode === 7) { // 忽略相位不计周期
1340
- continue
1341
- }
1342
- cycle = cycle + r.value
1343
- }
1344
- if (cycle > maxCycle && maxCycle === 0) {
1345
- maxCycle = cycle
1346
- }
1347
- if (cycle !== maxCycle) {
1348
- // this.patternmsg.push(rings.id)
1349
- isequal = false
1350
- }
1351
- }
1352
- return isequal
1353
- },
1354
- checkPatternRules (rings) {
1355
- if (!this.isRingCycleEqual(rings)) {
1356
- this.patternCycleEqual = false
1357
- } else {
1358
- this.patternCycleEqual = true
1359
- }
1360
- if (!this.patternCycleEqual) {
1361
- let mess = `方案中存在环周期时长不一致`
1362
- if (this.$i18n.locale === 'en') {
1363
- mess = `Inconsistent loop cycle durations exist in the scheme`
1364
- }
1365
- this.$message({
1366
- message: mess,
1367
- type: 'error',
1368
- dangerouslyUseHTMLString: true
1369
- })
1370
- return false
1371
- }
1372
- },
1373
- handleManualControl () {
1374
- let submitdata = {
1375
- control: 100,
1376
- delay: this.manualInfo.tempDelay !== undefined ? Number(this.manualInfo.tempDelay) : 0,
1377
- duration: Number(this.manualInfo.duration),
1378
- // duration: this.manualInfo.tempDuration !== undefined ? Number(this.manualInfo.tempDuration) : 0,
1379
- data: {}
1380
- }
1381
- submitdata.data.offset = this.offset
1382
- submitdata.data.cycle = this.cycle
1383
- submitdata.data.rings = this.rings
1384
- this.checkPatternRules(submitdata.data.rings)
1385
- if (this.patternCycleEqual) {
1386
- this.$emit('closePhaseControl', submitdata)
1387
- }
1388
- }
1389
- }
1390
- }
1391
- </script>
1392
-
1393
- <style>
1394
-
1395
- </style>
1
+ <template>
2
+ <div class="tentativeplan-control">
3
+ <div class="title" style="margin-bottom: 18px;">{{$t('openatccomponents.overview.tentativeplan')}}</div>
4
+ <el-row>
5
+ <el-col :span="12">
6
+ <el-form
7
+ ref="manual"
8
+ label-position="left"
9
+ :model="manualInfo"
10
+ label-width="100px">
11
+ <el-form-item
12
+ :label="$t('openatccomponents.overview.patternid') + ':'"
13
+ prop="count">
14
+ <el-select @change="selectPattern()" v-model="manualInfo.tempPatternid" class="col-inner" size="small" :placeholder="$t('openatccomponents.common.select')">
15
+ <el-option
16
+ v-for="item in patternSelect"
17
+ :key="item.value"
18
+ :label="item.label"
19
+ :value="item.value">
20
+ </el-option>
21
+ </el-select>
22
+ <!-- <el-input v-model="manualInfo.tempDuration" size="mini" :placeholder="$t('openatccomponents.common.input')"></el-input> -->
23
+ </el-form-item>
24
+ <el-form-item
25
+ :label="$t('openatccomponents.overview.delay') + ':'"
26
+ prop="intersection">
27
+ <el-input-number :placeholder="$t('openatccomponents.common.input')" :min="0" :max="65535" :precision="0" :step="1" :controls="false" v-model.number="manualInfo.tempDelay" size="mini"></el-input-number>
28
+ <!-- <el-input v-model="manualInfo.tempDelay" size="mini" :placeholder="$t('openatccomponents.common.input')"></el-input> -->
29
+ </el-form-item>
30
+ </el-form>
31
+ </el-col>
32
+ <el-col :span="12">
33
+ <el-form
34
+ ref="manual"
35
+ label-position="left"
36
+ :model="manualInfo"
37
+ label-width="100px">
38
+ <el-form-item
39
+ :label="$t('openatccomponents.overview.patternoffset') + ':'"
40
+ prop="count">
41
+ <el-input-number :placeholder="$t('openatccomponents.common.input')" :min="0" :max="65535" :precision="0" :step="1" :controls="false" v-model.number="manualInfo.offset" size="mini"></el-input-number>
42
+ <!-- <el-input v-model="manualInfo.offset" size="mini" :placeholder="$t('openatccomponents.common.input')"></el-input> -->
43
+ </el-form-item>
44
+ <el-form-item
45
+ :label="$t('openatccomponents.overview.duration') + ':'"
46
+ prop="intersection">
47
+ <el-input-number :placeholder="$t('openatccomponents.common.input')" :min="0" :max="65535" :precision="0" :step="1" :controls="false" v-model.number="manualInfo.duration" size="mini"></el-input-number>
48
+ <!-- <el-input v-model="manualInfo.duration" size="mini" :placeholder="$t('openatccomponents.common.input')"></el-input> -->
49
+ </el-form-item>
50
+ </el-form>
51
+ </el-col>
52
+ </el-row>
53
+ <el-row>
54
+ <div class="title" style="margin-top:18px; margin-bottom:10px">{{$t('openatccomponents.overview.patternstate')}}:
55
+ <span>({{$t('openatccomponents.overview.cycle')}}: {{cycle}} {{$t('openatccomponents.overview.patternoffset')}}: {{offset}})</span>
56
+ </div>
57
+ <stage-status
58
+ :patternStatusList="patternOne.length===0?planPattern.rings:patternOne[0].rings"
59
+ >
60
+ </stage-status>
61
+ <pattern-list
62
+ :patternList="patternOne.length===0?planPattern.rings:patternOne"
63
+ :patternStatusList="patternOne.length===0?planPattern.rings:patternOne[0].rings"
64
+ :cycles="patternOne.length===0?planPattern.cycle:patternOne[0].cycle"
65
+ :phaseList="phaseList">
66
+ </pattern-list>
67
+ </el-row>
68
+ <el-row>
69
+ <el-tabs v-model="activeList" type="card">
70
+ <el-tab-pane :label="$t('openatccomponents.pattern.ringConfig')" name="ring">
71
+ <div style="width: 100%; overflow: hidden;margin-top: 20px;">
72
+ <kan-ban v-for="n in ringCount"
73
+ :key="n" class="closephasekanban"
74
+ :index="n"
75
+ :options="patternOne.length===0?allPatternList[0].options:patternOne[0].options"
76
+ :list="patternOne.length===0?planPattern.rings[n-1]:patternOne[0].rings[n-1]"
77
+ :phaseList="phaseList"
78
+ :header-text="$t('openatccomponents.pattern.ring')+n"
79
+ @handleSplit="handleSplit">
80
+ </kan-ban>
81
+ </div>
82
+ </el-tab-pane>
83
+ <el-tab-pane :label="$t('openatccomponents.pattern.stageConfig')" name="kanban">
84
+ <el-scrollbar :vertical="true">
85
+ <div class="stage-panel-contener">
86
+ <stage-board v-for="(stage,index) in patternOne.length===0?allPatternList[0].stagesList:patternOne[0].stagesList"
87
+ class="closephasekanban"
88
+ :key="index"
89
+ :stage="stage"
90
+ :options="patternOne.length===0?allPatternList[0].options:patternOne[0].options"
91
+ :stageInfo="patternOne.length===0?allPatternList[0].stagesList:patternOne[0].stagesList"
92
+ :coordphaseOption="coordphaseOption"
93
+ :subIndex="index"
94
+ @onStageSplitChange="onStageSplitChange"
95
+ @stageSplitChange="stageSplitChange"
96
+ @onStageDelaystartChange="onStageDelaystartChange"
97
+ @onStageAdvanceendChange="onStageAdvanceendChange"
98
+ >
99
+ </stage-board>
100
+ </div>
101
+ </el-scrollbar>
102
+ </el-tab-pane>
103
+ <el-tab-pane :label="$t('openatccomponents.pattern.parameters')" name="parame">
104
+ <el-row>
105
+ <expend-config
106
+ v-for="(j,index) in ringCounts"
107
+ :key="index"
108
+ class="closephasekanban"
109
+ :options="patternOne.length===0?allPatternList[0].options:patternOne[0].options"
110
+ :header-text="$t('openatccomponents.pattern.ring')+j"
111
+ :list="patternOne.length===0?planPattern.rings[j-1]:patternOne[0].rings[j-1]"
112
+ >
113
+ </expend-config>
114
+ <div style="width: 60%;margin: 10px auto;color:#ffffff">
115
+ {{$t('openatccomponents.pattern.forbiddenstage')}}
116
+ <el-input class="stage-value" size="small" v-model="forbiddenstage"></el-input>
117
+ </div>
118
+ <div style="width: 60%;margin: 10px auto;color:#ffffff">
119
+ {{$t('openatccomponents.pattern.screenstage')}}
120
+ <el-input class="stage-value" size="small" v-model="screenstage"></el-input>
121
+ </div>
122
+ <div style="width: 60%;margin: 10px auto;color:#ffffff">
123
+ {{$t('openatccomponents.pattern.coordinatestage')}}
124
+ <el-input class="stage-value" size="small" v-model="coordinatestage"></el-input>
125
+ </div>
126
+ </el-row>
127
+ </el-tab-pane>
128
+ <el-tab-pane :label="$t('openatccomponents.pattern.overLap')" name="overlap">
129
+ <el-row :gutter="20">
130
+ <el-col :span="24" >
131
+ <over-lap
132
+ :stageList="stagesList"
133
+ :overlap="overlap"
134
+ :checked="true"
135
+ :tentative="true"
136
+ :cycle="patternOne.length===0?planPattern.cycle:patternOne[0].cycle"
137
+ >
138
+ </over-lap>
139
+ </el-col>
140
+ </el-row>
141
+ </el-tab-pane>
142
+ </el-tabs>
143
+ </el-row>
144
+ <div class="footer" v-if="realtimeStatusModalvisible">
145
+ <el-button @click="handleClose()">{{$t('openatccomponents.button.Back')}}</el-button>
146
+ <el-button type="primary" @click="handleManualControl()">{{$t('openatccomponents.overview.implement')}}</el-button>
147
+ </div>
148
+ <div class="footer" v-if="!realtimeStatusModalvisible">
149
+ <el-button @click="handleClose()">{{$t('openatccomponents.button.Back')}}</el-button>
150
+ <el-button type="primary" @click="handleManualControl()">{{$t('openatccomponents.overview.comfirm')}}</el-button>
151
+ </div>
152
+ </div>
153
+ </template>
154
+
155
+ <script>
156
+ export default {
157
+ name: 'tentativeplancontrol',
158
+ props: {
159
+ realtimeStatusModalvisible: {
160
+ type: Boolean,
161
+ default: true
162
+ },
163
+ controlData: {
164
+ type: Object
165
+ },
166
+ phaseList: {
167
+ type: Array
168
+ },
169
+ overlap: {
170
+ type: Array
171
+ },
172
+ allPatternList: {
173
+ type: Array
174
+ },
175
+ patternSelect: {
176
+ type: Array
177
+ }
178
+ },
179
+ computed: {
180
+ rings () {
181
+ return this.patternOne.length === 0 ? this.planPattern.rings : this.patternOne[0].rings
182
+ },
183
+ cycle () {
184
+ return this.patternOne.length === 0 ? this.max : (this.patternOne.length > 0 && (this.patternOne[0].cycle < this.max)) ? this.max : this.patternOne[0].cycle
185
+ },
186
+ offset () {
187
+ return Number((this.patternOne.length === 0 || this.manualInfo.offset > 0) ? this.manualInfo.offset : this.patternOne[0].offset)
188
+ },
189
+ forbiddenstage () {
190
+ return this.patternOne.length === 0 ? this.allPatternList[0].forbiddenstage : this.patternOne[0].forbiddenstage
191
+ },
192
+ screenstage () {
193
+ return this.patternOne.length === 0 ? this.allPatternList[0].screenstage : this.patternOne[0].screenstage
194
+ },
195
+ coordinatestage () {
196
+ return this.patternOne.length === 0 ? this.allPatternList[0].coordinatestage : this.patternOne[0].coordinatestage
197
+ }
198
+ },
199
+ data () {
200
+ return {
201
+ stagesList: [],
202
+ phaseRings: [],
203
+ options: {
204
+ group: 'pattern'
205
+ },
206
+ max: '',
207
+ patternCycleEqual: true,
208
+ activeList: 'ring',
209
+ ringCount: 1,
210
+ ringCounts: 1,
211
+ coordphaseOption: [],
212
+ patternOne: [],
213
+ planPattern: {},
214
+ manualInfo: {
215
+ tempPatternid: '',
216
+ offset: 0,
217
+ duration: 300,
218
+ tempDelay: 0 // 控制方式手动操作的情况下的延迟时间的临时值。
219
+ // tempDuration: 300 // 控制方式手动操作的情况下的持续时间的临时值。
220
+ }
221
+ }
222
+ },
223
+ created () {
224
+ this.patternPlan()
225
+ this.getCycle()
226
+ if (this.patternOne.length === 0) {
227
+ this.handleStageData(this.planPattern.rings)
228
+ }
229
+ this.initData()
230
+ },
231
+ methods: {
232
+ patternPlan () {
233
+ let Pattern = {
234
+ offset: 0,
235
+ cycle: 0,
236
+ rings: [[], [], [], []]
237
+ }
238
+ var newPattern = JSON.parse(JSON.stringify(Pattern))
239
+ for (let phase of this.phaseList) {
240
+ let ring = {}
241
+ ring.name = 'Phase ' + phase.id
242
+ ring.desc = this.getPhaseDescription(phase.direction)
243
+ ring.id = phase.id
244
+ ring.value = 30
245
+ ring.mode = 2
246
+ ring.options = []
247
+ ring.delaystart = 0
248
+ ring.advanceend = 0
249
+ if (phase.ring === 1) {
250
+ newPattern.rings[0].push(ring)
251
+ } else if (phase.ring === 2) {
252
+ newPattern.rings[1].push(ring)
253
+ } else if (phase.ring === 3) {
254
+ newPattern.rings[2].push(ring)
255
+ } else if (phase.ring === 4) {
256
+ newPattern.rings[3].push(ring)
257
+ }
258
+ }
259
+ this.planPattern = newPattern
260
+ },
261
+ getCycle () {
262
+ for (let rings of this.planPattern.rings) {
263
+ let num = 0
264
+ for (let i = 0; i < rings.length; i++) {
265
+ if (rings[i].length !== 0) {
266
+ if (rings[i].mode === 7) { // 忽略相位不计周期
267
+ continue
268
+ }
269
+ num = num + Number(rings[i].value)
270
+ }
271
+ }
272
+ if (num !== 0) {
273
+ this.planPattern.cycle = num
274
+ break
275
+ }
276
+ }
277
+ },
278
+ getPhaseDescription (phaseList) {
279
+ if (!phaseList) return
280
+ let list = []
281
+ for (let id of phaseList) {
282
+ let obj = {}
283
+ obj.id = id
284
+ obj.color = '#454545'
285
+ list.push(obj)
286
+ }
287
+ return list
288
+ },
289
+ handleClose () {
290
+ this.$emit('closePhaseBack')
291
+ },
292
+ onStageSplitChange (diff, rowIndex, subIndex) {
293
+ let stageArr = this.stagesList[subIndex].stages
294
+ let row = this.patternList[rowIndex]
295
+ let ringsList = row.rings
296
+ for (let rings of ringsList) {
297
+ for (let ring of rings) {
298
+ if (stageArr.includes(ring.id)) {
299
+ ring.value = (ring.value ? ring.value : 0) + diff
300
+ continue
301
+ }
302
+ }
303
+ }
304
+ },
305
+ stageSplitChange (diff, rowIndex, subIndex) {
306
+ let row = this.patternList[rowIndex]
307
+ let ringsList = row.stagesList
308
+ for (let rings of ringsList) {
309
+ if (subIndex === rings.key) {
310
+ rings.stageSplit = (rings.green ? rings.green : 0) + (rings.yellow ? rings.yellow : 0) + (rings.red ? rings.red : 0)
311
+ continue
312
+ }
313
+ }
314
+ },
315
+ onStageDelaystartChange (diff, rowIndex, subIndex) {
316
+ let stageArr = this.stagesList[subIndex].stages
317
+ let row = this.patternList[rowIndex]
318
+ let ringsList = row.rings
319
+ for (let rings of ringsList) {
320
+ for (let ring of rings) {
321
+ if (stageArr.includes(ring.id)) {
322
+ ring.delaystart = (ring.delaystart ? ring.delaystart : 0) + diff
323
+ continue
324
+ }
325
+ }
326
+ }
327
+ },
328
+ onStageAdvanceendChange (diff, rowIndex, subIndex) {
329
+ let stageArr = this.stagesList[subIndex].stages
330
+ let row = this.patternList[rowIndex]
331
+ let ringsList = row.rings
332
+ for (let rings of ringsList) {
333
+ for (let ring of rings) {
334
+ if (stageArr.includes(ring.id)) {
335
+ ring.advanceend = (ring.advanceend ? ring.advanceend : 0) + diff
336
+ continue
337
+ }
338
+ }
339
+ }
340
+ },
341
+ handleSplit (index) {
342
+ if (this.patternOne.length > 0) {
343
+ let currPattern = this.patternOne[0].rings
344
+ setTimeout(() => {
345
+ this.handleStageData(currPattern)
346
+ }, 50)
347
+ } else {
348
+ let currPattern = this.planPattern.rings
349
+ setTimeout(() => {
350
+ this.handleStageData(currPattern)
351
+ }, 50)
352
+ }
353
+ },
354
+ selectPattern () {
355
+ this.manualInfo.offset = 0
356
+ let selectId = Number(this.manualInfo.tempPatternid)
357
+ this.patternOne = this.allPatternList.filter(item => {
358
+ return item.id === selectId
359
+ })
360
+ this.manualInfo.offset = this.offset
361
+ for (let rings of this.patternOne[0].rings) {
362
+ if (rings.length === 0) continue
363
+ for (let ring of rings) {
364
+ if (ring.value === 0) continue
365
+ let currPhase = this.phaseList.filter((item) => {
366
+ return item.id === ring.id
367
+ })[0]
368
+ ring.desc = currPhase.direction.map(item => {
369
+ return {
370
+ id: item,
371
+ color: '#454545'
372
+ }
373
+ })
374
+ }
375
+ }
376
+ this.handleStageData(this.patternOne[0].rings)
377
+ },
378
+ handleStageData (rings) { // stagesList
379
+ for (let i = 0; i < rings.length; i++) {
380
+ if (rings[i].length > 0) {
381
+ let phaseList = []
382
+ let stagesList = []
383
+ // rings = JSON.parse(JSON.stringify(rings))
384
+ let mapAdd = rings.map(item => {
385
+ return item.map(val => {
386
+ return val.value + (val.sum ? val.sum : 0)
387
+ })
388
+ })
389
+ let maxCycle = mapAdd.length > 0 ? mapAdd.map(item => {
390
+ return item.length > 0 ? item.reduce((a, b) => {
391
+ return a + b
392
+ }) : 0
393
+ }) : 0
394
+ this.max = Math.max(...maxCycle)// 每个环的周期最大值
395
+ this.stateList = [0]
396
+ this.narr = []
397
+ let currentIds = ''
398
+ let lastCurrentIds = ''
399
+ for (let j = 0; j <= this.max; j++) { // 指针长度
400
+ for (let i = 0; i < rings.length; i++) { // 环列表
401
+ let ring = rings[i]// 每个环对象
402
+ let sum = 0
403
+ for (let n = 0; n < ring.length; n++) { // 相位累计长度
404
+ if (ring[n].mode !== 7) {
405
+ sum = sum + ring[n].value + (ring[n].sum ? ring[n].sum : 0)
406
+ if (j < sum) {
407
+ let phaseId = ring[n].id
408
+ currentIds = currentIds + '-' + phaseId
409
+ break
410
+ }
411
+ }
412
+ }
413
+ }
414
+ if (lastCurrentIds !== currentIds && lastCurrentIds !== '') { // 当前相位id和上一个相比不同说明相位变化了
415
+ phaseList.push(lastCurrentIds)
416
+ this.stateList.push(j)// 阶段累计长度的集合
417
+ }
418
+ lastCurrentIds = currentIds
419
+ currentIds = ''
420
+ }
421
+ let newPhaselist = []
422
+ phaseList.forEach(i => {
423
+ let rangeArr = i.split('-').map(Number)
424
+ if (rangeArr.length > 2) {
425
+ newPhaselist.push([
426
+ JSON.parse(JSON.stringify(rangeArr[1])),
427
+ JSON.parse(JSON.stringify(rangeArr[2]))
428
+ ])
429
+ } else {
430
+ newPhaselist.push([
431
+ JSON.parse(JSON.stringify(rangeArr[1]))
432
+ ])
433
+ }
434
+ })
435
+ for (let i = this.stateList.length - 1; i >= 1; i--) {
436
+ this.narr.push(this.stateList[i] - this.stateList[i - 1])
437
+ }
438
+ // newPhaselist
439
+ this.narr.reverse()// 阶段差
440
+ for (let i = 0; i < newPhaselist.length; i++) {
441
+ let stage = JSON.parse(JSON.stringify(newPhaselist[i]))
442
+ let stageItem = this.getStageItem(stage, rings, i)
443
+ stagesList.push(JSON.parse(JSON.stringify(stageItem)))
444
+ }
445
+ this.stagesList = JSON.parse(JSON.stringify(stagesList))
446
+ }
447
+ }
448
+ },
449
+ getStageItem (stageArr, ringsList, i) {
450
+ let res = {
451
+ key: i,
452
+ split: this.narr[i], // 阶段绿性比
453
+ stages: stageArr,
454
+ delaystart: 0,
455
+ advanceend: 0
456
+ }
457
+ // let splitArr = []
458
+ let delaystartArr = []
459
+ let advanceendArr = []
460
+ for (let rings of ringsList) {
461
+ for (let ring of rings) {
462
+ if (stageArr.includes(ring.id)) {
463
+ // let split = ring.value
464
+ let delaystart = ring.delaystart
465
+ let advanceend = ring.advanceend
466
+ // splitArr.push(split)
467
+ delaystartArr.push(delaystart)
468
+ advanceendArr.push(advanceend)
469
+ }
470
+ }
471
+ }
472
+ // splitArr.sort(function (a, b) { return a - b })
473
+ delaystartArr.sort(function (a, b) { return b - a })
474
+ advanceendArr.sort(function (a, b) { return a - b })
475
+ // res.split = splitArr.length > 0 ? splitArr[0] : 0
476
+ res.delaystart = delaystartArr.length > 0 ? delaystartArr[0] : 0
477
+ res.advanceend = advanceendArr.length > 0 ? advanceendArr[0] : 0
478
+ return res
479
+ },
480
+ initData () {
481
+ // 判断有几个环,就创建几个看板
482
+ // let phaseList = this.globalParamModel.getParamsByType('phaseList')
483
+ this.coordphaseOption = this.phaseList.map(ele => {
484
+ return {
485
+ value: ele.id
486
+ }
487
+ })
488
+ // this.overlap = this.globalParamModel.getParamsByType('overlaplList')
489
+ // this.agentId = getIframdevid()
490
+ let rings = []
491
+ if (this.phaseList.length === 0) {
492
+ // this.$store.getters.tscParam.patternList = []
493
+ return
494
+ }
495
+ for (let phase of this.phaseList) {
496
+ rings.push(phase.ring)
497
+ }
498
+ this.ringCount = Array.from(new Set(rings)) // 去除数组重复的元素
499
+ this.ringCount = this.ringCount.sort(this.sortNumbers) // 把数组中的值按照从小到大的顺序重新排序
500
+ this.ringCounts = Array.from(new Set(rings)) // 去除数组重复的元素
501
+ this.ringCounts = this.ringCounts.sort(this.sortNumbers) // 把数组中的值按照从小到大的顺序重新排序
502
+ // this.increaseId()
503
+ // this.getCycle()
504
+ // this.updatePhaseDescription()
505
+ // this.getOptionsOfRing()
506
+ },
507
+ sortNumbers (a, b) {
508
+ return a - b
509
+ },
510
+ isRingCycleEqual (rings) {
511
+ let isequal = true
512
+ // this.patternmsg = []
513
+ let maxCycle = 0
514
+ for (let ring of rings) {
515
+ if (ring.length === 0) continue
516
+ let cycle = 0
517
+ for (let r of ring) {
518
+ if (r.mode === 7) { // 忽略相位不计周期
519
+ continue
520
+ }
521
+ cycle = cycle + r.value
522
+ }
523
+ if (cycle > maxCycle && maxCycle === 0) {
524
+ maxCycle = cycle
525
+ }
526
+ if (cycle !== maxCycle) {
527
+ // this.patternmsg.push(rings.id)
528
+ isequal = false
529
+ }
530
+ }
531
+ return isequal
532
+ },
533
+ checkPatternRules (rings) {
534
+ if (!this.isRingCycleEqual(rings)) {
535
+ this.patternCycleEqual = false
536
+ } else {
537
+ this.patternCycleEqual = true
538
+ }
539
+ if (!this.patternCycleEqual) {
540
+ let mess = `方案中存在环周期时长不一致`
541
+ if (this.$i18n.locale === 'en') {
542
+ mess = `Inconsistent loop cycle durations exist in the scheme`
543
+ }
544
+ this.$message({
545
+ message: mess,
546
+ type: 'error',
547
+ dangerouslyUseHTMLString: true
548
+ })
549
+ return false
550
+ }
551
+ },
552
+ handleManualControl () {
553
+ let submitdata = {
554
+ control: 100,
555
+ delay: this.manualInfo.tempDelay !== undefined ? Number(this.manualInfo.tempDelay) : 0,
556
+ duration: Number(this.manualInfo.duration),
557
+ // duration: this.manualInfo.tempDuration !== undefined ? Number(this.manualInfo.tempDuration) : 0,
558
+ data: {}
559
+ }
560
+ submitdata.data.offset = this.offset
561
+ submitdata.data.cycle = this.cycle
562
+ submitdata.data.rings = this.rings
563
+ this.checkPatternRules(submitdata.data.rings)
564
+ if (this.patternCycleEqual) {
565
+ this.$emit('closePhaseControl', submitdata)
566
+ }
567
+ }
568
+ }
569
+ }
570
+ </script>
571
+
572
+ <style>
573
+
574
+ </style>