openatc-components 0.5.37 → 0.5.39

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 (346) hide show
  1. package/.babelrc +18 -18
  2. package/.editorconfig +9 -9
  3. package/.eslintignore +5 -5
  4. package/.eslintrc.js +31 -31
  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 +120 -120
  15. package/build/webpack.dev.conf.js +95 -95
  16. package/build/webpack.prod.conf.js +149 -149
  17. package/config/prod.env.js +5 -5
  18. package/config/test.env.js +7 -7
  19. package/index.html +12 -12
  20. package/package/kisscomps/components/Channelization/Channelization.vue +585 -585
  21. package/package/kisscomps/components/ChannelizationFlowStatistic/ChannelizationFlowStatistic.vue +360 -360
  22. package/package/kisscomps/components/ChannelizationWithInterface/ChannelizationWithInterface.vue +518 -518
  23. package/package/kisscomps/components/CommonKanban/CommonKanban.vue +132 -132
  24. package/package/kisscomps/components/DirectionListConfiguration/svg/ped-east-bottom.vue +41 -41
  25. package/package/kisscomps/components/DirectionListConfiguration/svg/ped-east-top.vue +60 -60
  26. package/package/kisscomps/components/DirectionListConfiguration/svg/ped-ewped.vue +105 -105
  27. package/package/kisscomps/components/DirectionListConfiguration/svg/ped-north-left.vue +60 -60
  28. package/package/kisscomps/components/DirectionListConfiguration/svg/ped-north-right.vue +60 -60
  29. package/package/kisscomps/components/DirectionListConfiguration/svg/ped-snped.vue +105 -105
  30. package/package/kisscomps/components/DirectionListConfiguration/svg/ped-south-left.vue +60 -60
  31. package/package/kisscomps/components/DirectionListConfiguration/svg/ped-south-right.vue +60 -60
  32. package/package/kisscomps/components/DirectionListConfiguration/svg/ped-west-bottom.vue +60 -60
  33. package/package/kisscomps/components/DirectionListConfiguration/svg/ped-west-top.vue +60 -60
  34. package/package/kisscomps/components/DirectionListConfiguration/svg/ped-xlped.vue +30 -30
  35. package/package/kisscomps/components/DirectionListConfiguration/svg/ped-xrped.vue +30 -30
  36. package/package/kisscomps/components/DirectionListConfiguration/svg/pedSvg.vue +78 -78
  37. package/package/kisscomps/components/DrawChannelization/drawsvg/basicCoordInfo.vue +181 -181
  38. package/package/kisscomps/components/DrawChannelization/drawsvg/channelizationElements.vue +255 -255
  39. package/package/kisscomps/components/DrawChannelization/drawsvg/detectorAssociatedComponent.vue +152 -152
  40. package/package/kisscomps/components/DrawChannelization/drawsvg/drawElement/TextBox.vue +91 -91
  41. package/package/kisscomps/components/DrawChannelization/drawsvg/drawElement/editText.vue +108 -108
  42. package/package/kisscomps/components/DrawChannelization/drawsvg/firstImportCrossmap.vue +51 -51
  43. package/package/kisscomps/components/DrawChannelization/drawsvg/iconSvg/countdownSvg.vue +236 -236
  44. package/package/kisscomps/components/DrawChannelization/drawsvg/iconSvg/detectorChart.vue +247 -247
  45. package/package/kisscomps/components/DrawChannelization/drawsvg/iconSvg/detectorIconSvg.vue +210 -210
  46. package/package/kisscomps/components/DrawChannelization/drawsvg/iconSvg/laneIcon.vue +72 -72
  47. package/package/kisscomps/components/DrawChannelization/drawsvg/iconSvg/motorwayIconSvg.vue +368 -368
  48. package/package/kisscomps/components/DrawChannelization/drawsvg/iconSvg/pedroadIconSvg.vue +230 -230
  49. package/package/kisscomps/components/DrawChannelization/drawsvg/importDialog.vue +74 -74
  50. package/package/kisscomps/components/DrawChannelization/drawsvg/index.vue +144 -144
  51. package/package/kisscomps/components/DrawChannelization/drawsvg/laneEditPanel.vue +707 -707
  52. package/package/kisscomps/components/DrawChannelization/drawsvg/overlapAssociatedComponent.vue +172 -172
  53. package/package/kisscomps/components/DrawChannelization/drawsvg/table.vue +99 -99
  54. package/package/kisscomps/components/DrawChannelization/drawsvg/utils/loadutils.js +87 -87
  55. package/package/kisscomps/components/DrawChannelization/drawsvg/utils/phaseDataModel.js +32 -32
  56. package/package/kisscomps/components/DrawChannelization/drawsvg/utils/phasePos.json +20 -20
  57. package/package/kisscomps/components/DrawChannelization/phaseDataMgr.js +278 -278
  58. package/package/kisscomps/components/ExpendConfig/ExpendConfig.vue +118 -118
  59. package/package/kisscomps/components/FaultDetailModal/FaultDetailModal.vue +178 -178
  60. package/package/kisscomps/components/IntersectionMap/crossDirection/baseImg/CrossRoadsSvg.vue +629 -629
  61. package/package/kisscomps/components/IntersectionMap/crossDirection/baseImg/CustomRoadsSvg.vue +46 -46
  62. package/package/kisscomps/components/IntersectionMap/crossDirection/baseImg/PedSectionEWSvg.vue +447 -447
  63. package/package/kisscomps/components/IntersectionMap/crossDirection/baseImg/PedSectionSNSvg.vue +341 -341
  64. package/package/kisscomps/components/IntersectionMap/crossDirection/baseImg/RampEastSvg.vue +497 -497
  65. package/package/kisscomps/components/IntersectionMap/crossDirection/baseImg/RampNorthSvg.vue +353 -353
  66. package/package/kisscomps/components/IntersectionMap/crossDirection/baseImg/RampSouthSvg.vue +359 -359
  67. package/package/kisscomps/components/IntersectionMap/crossDirection/baseImg/RampWestSvg.vue +443 -443
  68. package/package/kisscomps/components/IntersectionMap/crossDirection/baseImg/SidewalkSvg.vue +1190 -1190
  69. package/package/kisscomps/components/IntersectionMap/crossDirection/baseImg/TShapeEastRoadsSvg.vue +498 -498
  70. package/package/kisscomps/components/IntersectionMap/crossDirection/baseImg/TShapeNorthRoadsSvg.vue +484 -484
  71. package/package/kisscomps/components/IntersectionMap/crossDirection/baseImg/TShapeSouthRoadsSvg.vue +488 -488
  72. package/package/kisscomps/components/IntersectionMap/crossDirection/baseImg/TShapeWestRoadsSvg.vue +566 -566
  73. package/package/kisscomps/components/IntersectionMap/crossDirection/baseImg/leftroad/LCrossRoadsSvg.vue +640 -640
  74. package/package/kisscomps/components/IntersectionMap/crossDirection/baseImg/leftroad/LTShapeEastRoadsSvg.vue +497 -497
  75. package/package/kisscomps/components/IntersectionMap/crossDirection/baseImg/leftroad/LTShapeNorthRoadsSvg.vue +486 -486
  76. package/package/kisscomps/components/IntersectionMap/crossDirection/baseImg/leftroad/LTShapeSouthRoadsSvg.vue +490 -490
  77. package/package/kisscomps/components/IntersectionMap/crossDirection/baseImg/leftroad/LTShapeWestRoadsSvg.vue +575 -575
  78. package/package/kisscomps/components/IntersectionMap/crossDirection/baseImg/refreshSvg.vue +63 -63
  79. package/package/kisscomps/components/IntersectionMap/crossDirection/busIcon/busMapSvg.vue +50 -50
  80. package/package/kisscomps/components/IntersectionMap/crossDirection/busIcon/eastBusSvg.vue +167 -167
  81. package/package/kisscomps/components/IntersectionMap/crossDirection/busIcon/northBusSvg.vue +168 -168
  82. package/package/kisscomps/components/IntersectionMap/crossDirection/busIcon/southBusSvg.vue +168 -168
  83. package/package/kisscomps/components/IntersectionMap/crossDirection/busIcon/westBusSvg.vue +169 -169
  84. package/package/kisscomps/components/IntersectionMap/crossDirection/phaseIcon/rampPhaseIconSvg.vue +122 -122
  85. package/package/kisscomps/components/IntersectionMap/crossDirection/posJson/busPos.json +196 -196
  86. package/package/kisscomps/components/IntersectionMap/crossDirection/posJson/busPos.left.json +196 -196
  87. package/package/kisscomps/components/IntersectionMap/crossDirection/posJson/rampPos.json +52 -52
  88. package/package/kisscomps/components/KanBan/kanban.vue +231 -231
  89. package/package/kisscomps/components/MessageBox/index.vue +96 -96
  90. package/package/kisscomps/components/OptimizeKanban/index.js +2 -0
  91. package/package/kisscomps/components/OptimizeKanban/index.vue +369 -0
  92. package/package/kisscomps/components/OverLap/OverLap.vue +130 -11
  93. package/package/kisscomps/components/PatternOptimize/PatternOptimize.vue +329 -329
  94. package/package/kisscomps/components/PatternWalkSvg/PatternWalkSvg.vue +423 -423
  95. package/package/kisscomps/components/PhaseDirectionSelect/PhaseDirectionSelect.vue +126 -126
  96. package/package/kisscomps/components/PhaseDirectionText/PhaseDirectionText.vue +106 -106
  97. package/package/kisscomps/components/PhaseLegend/PhaseLegend.vue +286 -286
  98. package/package/kisscomps/components/PhaseMarker/index.js +6 -6
  99. package/package/kisscomps/components/PhaseMarker/phasemarker.vue +215 -215
  100. package/package/kisscomps/components/PhaseMarker/svg/patternSvg.vue +121 -121
  101. package/package/kisscomps/components/PhaseMarker/svg/phase.vue +60 -60
  102. package/package/kisscomps/components/PhaseMarker/svg/phaseCount.vue +62 -62
  103. package/package/kisscomps/components/PhaseMarker/svg/phaseCountCycle.vue +62 -62
  104. package/package/kisscomps/components/PhaseMarker/svg/phaseSvg.vue +117 -117
  105. package/package/kisscomps/components/PhasePedSelect/index.vue +206 -206
  106. package/package/kisscomps/components/SchemeConfig/azimuthlocking/index.vue +365 -365
  107. package/package/kisscomps/components/SchemeConfig/azimuthlocking/utils.js +92 -92
  108. package/package/kisscomps/components/SchemeConfig/closePhaselControlModal/index.vue +214 -214
  109. package/package/kisscomps/components/SchemeConfig/lockingPhaselControlModal/index.vue +235 -235
  110. package/package/kisscomps/components/SchemeConfig/manualControlModal/index.vue +235 -235
  111. package/package/kisscomps/components/SchemeConfig/manualControlModalNew/controlModelGroup.vue +131 -131
  112. package/package/kisscomps/components/SchemeConfig/manualControlModalNew/othersIcon.vue +151 -151
  113. package/package/kisscomps/components/SchemeConfig/priorityControl/index.vue +215 -215
  114. package/package/kisscomps/components/SchemeConfig/priorityControl/utils.js +163 -163
  115. package/package/kisscomps/components/SchemeConfig/utils/thirdPartypermission.js +95 -95
  116. package/package/kisscomps/components/StageOptimize/StageOptimize.vue +367 -367
  117. package/package/kisscomps/components/StageOptimize/index.js +2 -2
  118. package/package/kisscomps/components/StageOptimize/index.vue +310 -0
  119. package/package/kisscomps/components/StageStatus/StageStatus.vue +341 -341
  120. package/package/kisscomps/components/SvgIcon/SvgIcon.vue +53 -53
  121. package/package/kisscomps/components/XiaoKanban/DirSelector.vue +356 -356
  122. package/package/kisscomps/components/XiaoKanban/index.vue +122 -122
  123. package/package/kisscomps/components/patternConfig/pattern/planChart/model/coordinationModel.js +665 -665
  124. package/package/kisscomps/components/patternConfig/planContent.vue +604 -604
  125. package/package/kisscomps/components/patternConfig/planMenu.vue +329 -329
  126. package/package/kissui.min.js +1 -1
  127. package/package.json +1 -1
  128. package/src/EdgeMgr/EdgeModelBase.js +16 -16
  129. package/src/EdgeMgr/controller/crossDiagramMgr.js +125 -125
  130. package/src/api/authapi.js +31 -31
  131. package/src/api/config.js +21 -21
  132. package/src/api/control.js +110 -110
  133. package/src/api/device.js +135 -135
  134. package/src/api/fault.js +66 -66
  135. package/src/api/index.js +24 -24
  136. package/src/api/login.js +46 -46
  137. package/src/api/optimize.js +72 -72
  138. package/src/api/passwdAssest.js +101 -101
  139. package/src/api/permission.js +33 -33
  140. package/src/api/route.js +171 -171
  141. package/src/assets/font/LICENSE.txt +202 -202
  142. package/src/assets/font/font.css +6 -6
  143. package/src/i18n/index.js +26 -26
  144. package/src/icons/index.js +20 -20
  145. package/src/icons/svg/azimuthlocking.svg +26 -26
  146. package/src/icons/svg/bendi.svg +110 -110
  147. package/src/icons/svg/bujin.svg +36 -36
  148. package/src/icons/svg/connectBlue.svg +7 -7
  149. package/src/icons/svg/currentvolume.svg +0 -0
  150. package/src/icons/svg/custom-BRTlane.svg +40 -40
  151. package/src/icons/svg/custom-buslane.svg +40 -40
  152. package/src/icons/svg/custom-detector.svg +12 -12
  153. package/src/icons/svg/custom-east-bottom.svg +32 -32
  154. package/src/icons/svg/custom-east-top.svg +32 -32
  155. package/src/icons/svg/custom-ewped.svg +35 -35
  156. package/src/icons/svg/custom-nonmotorizedlane.svg +40 -40
  157. package/src/icons/svg/custom-north-left.svg +32 -32
  158. package/src/icons/svg/custom-north-right.svg +32 -32
  159. package/src/icons/svg/custom-peddetector.svg +17 -17
  160. package/src/icons/svg/custom-snped.svg +35 -35
  161. package/src/icons/svg/custom-south-left.svg +32 -32
  162. package/src/icons/svg/custom-south-right.svg +32 -32
  163. package/src/icons/svg/custom-tramlane.svg +40 -40
  164. package/src/icons/svg/custom-vehiclebranch.svg +40 -40
  165. package/src/icons/svg/custom-vehiclemainroad.svg +41 -41
  166. package/src/icons/svg/custom-west-bottom.svg +32 -32
  167. package/src/icons/svg/custom-west-top.svg +32 -32
  168. package/src/icons/svg/custom-xlped.svg +14 -14
  169. package/src/icons/svg/custom-xrped.svg +14 -14
  170. package/src/icons/svg/cutRed.svg +7 -7
  171. package/src/icons/svg/cycle.svg +0 -0
  172. package/src/icons/svg/dingzhouqi.svg +34 -34
  173. package/src/icons/svg/ganyingkongzhi.svg +30 -30
  174. package/src/icons/svg/guandeng.svg +81 -81
  175. package/src/icons/svg/huangshan.svg +71 -71
  176. package/src/icons/svg/maincontrol.svg +0 -0
  177. package/src/icons/svg/manualcontrolbackground.svg +51 -51
  178. package/src/icons/svg/manualcontrolbackground1.svg +62 -62
  179. package/src/icons/svg/manualcontrolbackgrounden.svg +62 -62
  180. package/src/icons/svg/model.svg +0 -0
  181. package/src/icons/svg/phasediff.svg +0 -0
  182. package/src/icons/svg/prioritycontrol.svg +21 -21
  183. package/src/icons/svg/quanhong.svg +86 -86
  184. package/src/icons/svg/shanghe.svg +11 -11
  185. package/src/icons/svg/shoudong.svg +103 -103
  186. package/src/icons/svg/tentativeplan.svg +28 -28
  187. package/src/icons/svg/time.svg +0 -0
  188. package/src/icons/svg/wuxianlan.svg +46 -46
  189. package/src/icons/svg/xiala.svg +11 -11
  190. package/src/icons/svg/xingrenguojie.svg +33 -33
  191. package/src/icons/svg/xitong.svg +89 -89
  192. package/src/icons/svg/youxian.svg +41 -41
  193. package/src/icons/svg/zizhukongzhi.svg +43 -43
  194. package/src/kisscomps/components/Channelization/Channelization.vue +585 -585
  195. package/src/kisscomps/components/ChannelizationFlowStatistic/ChannelizationFlowStatistic.vue +360 -360
  196. package/src/kisscomps/components/ChannelizationWithInterface/ChannelizationWithInterface.vue +518 -518
  197. package/src/kisscomps/components/CommonKanban/CommonKanban.vue +132 -132
  198. package/src/kisscomps/components/DirectionListConfiguration/svg/ped-east-bottom.vue +41 -41
  199. package/src/kisscomps/components/DirectionListConfiguration/svg/ped-east-top.vue +60 -60
  200. package/src/kisscomps/components/DirectionListConfiguration/svg/ped-ewped.vue +105 -105
  201. package/src/kisscomps/components/DirectionListConfiguration/svg/ped-north-left.vue +60 -60
  202. package/src/kisscomps/components/DirectionListConfiguration/svg/ped-north-right.vue +60 -60
  203. package/src/kisscomps/components/DirectionListConfiguration/svg/ped-snped.vue +105 -105
  204. package/src/kisscomps/components/DirectionListConfiguration/svg/ped-south-left.vue +60 -60
  205. package/src/kisscomps/components/DirectionListConfiguration/svg/ped-south-right.vue +60 -60
  206. package/src/kisscomps/components/DirectionListConfiguration/svg/ped-west-bottom.vue +60 -60
  207. package/src/kisscomps/components/DirectionListConfiguration/svg/ped-west-top.vue +60 -60
  208. package/src/kisscomps/components/DirectionListConfiguration/svg/ped-xlped.vue +30 -30
  209. package/src/kisscomps/components/DirectionListConfiguration/svg/ped-xrped.vue +30 -30
  210. package/src/kisscomps/components/DirectionListConfiguration/svg/pedSvg.vue +78 -78
  211. package/src/kisscomps/components/DrawChannelization/drawsvg/basicCoordInfo.vue +181 -181
  212. package/src/kisscomps/components/DrawChannelization/drawsvg/channelizationElements.vue +255 -255
  213. package/src/kisscomps/components/DrawChannelization/drawsvg/detectorAssociatedComponent.vue +152 -152
  214. package/src/kisscomps/components/DrawChannelization/drawsvg/drawElement/TextBox.vue +91 -91
  215. package/src/kisscomps/components/DrawChannelization/drawsvg/drawElement/editText.vue +108 -108
  216. package/src/kisscomps/components/DrawChannelization/drawsvg/firstImportCrossmap.vue +51 -51
  217. package/src/kisscomps/components/DrawChannelization/drawsvg/iconSvg/countdownSvg.vue +236 -236
  218. package/src/kisscomps/components/DrawChannelization/drawsvg/iconSvg/detectorChart.vue +247 -247
  219. package/src/kisscomps/components/DrawChannelization/drawsvg/iconSvg/detectorIconSvg.vue +210 -210
  220. package/src/kisscomps/components/DrawChannelization/drawsvg/iconSvg/laneIcon.vue +72 -72
  221. package/src/kisscomps/components/DrawChannelization/drawsvg/iconSvg/motorwayIconSvg.vue +368 -368
  222. package/src/kisscomps/components/DrawChannelization/drawsvg/iconSvg/pedroadIconSvg.vue +230 -230
  223. package/src/kisscomps/components/DrawChannelization/drawsvg/importDialog.vue +74 -74
  224. package/src/kisscomps/components/DrawChannelization/drawsvg/index.vue +144 -144
  225. package/src/kisscomps/components/DrawChannelization/drawsvg/laneEditPanel.vue +707 -707
  226. package/src/kisscomps/components/DrawChannelization/drawsvg/overlapAssociatedComponent.vue +172 -172
  227. package/src/kisscomps/components/DrawChannelization/drawsvg/table.vue +99 -99
  228. package/src/kisscomps/components/DrawChannelization/drawsvg/utils/loadutils.js +87 -87
  229. package/src/kisscomps/components/DrawChannelization/drawsvg/utils/phaseDataModel.js +32 -32
  230. package/src/kisscomps/components/DrawChannelization/drawsvg/utils/phasePos.json +20 -20
  231. package/src/kisscomps/components/DrawChannelization/phaseDataMgr.js +278 -278
  232. package/src/kisscomps/components/ExpendConfig/ExpendConfig.vue +118 -118
  233. package/src/kisscomps/components/FaultDetailModal/FaultDetailModal.vue +178 -178
  234. package/src/kisscomps/components/IntersectionMap/crossDirection/baseImg/CrossRoadsSvg.vue +629 -629
  235. package/src/kisscomps/components/IntersectionMap/crossDirection/baseImg/CustomRoadsSvg.vue +46 -46
  236. package/src/kisscomps/components/IntersectionMap/crossDirection/baseImg/PedSectionEWSvg.vue +447 -447
  237. package/src/kisscomps/components/IntersectionMap/crossDirection/baseImg/PedSectionSNSvg.vue +341 -341
  238. package/src/kisscomps/components/IntersectionMap/crossDirection/baseImg/RampEastSvg.vue +497 -497
  239. package/src/kisscomps/components/IntersectionMap/crossDirection/baseImg/RampNorthSvg.vue +353 -353
  240. package/src/kisscomps/components/IntersectionMap/crossDirection/baseImg/RampSouthSvg.vue +359 -359
  241. package/src/kisscomps/components/IntersectionMap/crossDirection/baseImg/RampWestSvg.vue +443 -443
  242. package/src/kisscomps/components/IntersectionMap/crossDirection/baseImg/SidewalkSvg.vue +1190 -1190
  243. package/src/kisscomps/components/IntersectionMap/crossDirection/baseImg/TShapeEastRoadsSvg.vue +498 -498
  244. package/src/kisscomps/components/IntersectionMap/crossDirection/baseImg/TShapeNorthRoadsSvg.vue +484 -484
  245. package/src/kisscomps/components/IntersectionMap/crossDirection/baseImg/TShapeSouthRoadsSvg.vue +488 -488
  246. package/src/kisscomps/components/IntersectionMap/crossDirection/baseImg/TShapeWestRoadsSvg.vue +566 -566
  247. package/src/kisscomps/components/IntersectionMap/crossDirection/baseImg/leftroad/LCrossRoadsSvg.vue +640 -640
  248. package/src/kisscomps/components/IntersectionMap/crossDirection/baseImg/leftroad/LTShapeEastRoadsSvg.vue +497 -497
  249. package/src/kisscomps/components/IntersectionMap/crossDirection/baseImg/leftroad/LTShapeNorthRoadsSvg.vue +486 -486
  250. package/src/kisscomps/components/IntersectionMap/crossDirection/baseImg/leftroad/LTShapeSouthRoadsSvg.vue +490 -490
  251. package/src/kisscomps/components/IntersectionMap/crossDirection/baseImg/leftroad/LTShapeWestRoadsSvg.vue +575 -575
  252. package/src/kisscomps/components/IntersectionMap/crossDirection/baseImg/refreshSvg.vue +63 -63
  253. package/src/kisscomps/components/IntersectionMap/crossDirection/busIcon/busMapSvg.vue +50 -50
  254. package/src/kisscomps/components/IntersectionMap/crossDirection/busIcon/eastBusSvg.vue +167 -167
  255. package/src/kisscomps/components/IntersectionMap/crossDirection/busIcon/northBusSvg.vue +168 -168
  256. package/src/kisscomps/components/IntersectionMap/crossDirection/busIcon/southBusSvg.vue +168 -168
  257. package/src/kisscomps/components/IntersectionMap/crossDirection/busIcon/westBusSvg.vue +169 -169
  258. package/src/kisscomps/components/IntersectionMap/crossDirection/phaseIcon/rampPhaseIconSvg.vue +122 -122
  259. package/src/kisscomps/components/IntersectionMap/crossDirection/posJson/busPos.json +196 -196
  260. package/src/kisscomps/components/IntersectionMap/crossDirection/posJson/busPos.left.json +196 -196
  261. package/src/kisscomps/components/IntersectionMap/crossDirection/posJson/rampPos.json +52 -52
  262. package/src/kisscomps/components/KanBan/kanban.vue +231 -231
  263. package/src/kisscomps/components/MessageBox/index.vue +96 -96
  264. package/src/kisscomps/components/OverLap/OverLap.vue +130 -11
  265. package/src/kisscomps/components/PatternOptimize/PatternOptimize.vue +329 -329
  266. package/src/kisscomps/components/PatternWalkSvg/PatternWalkSvg.vue +423 -423
  267. package/src/kisscomps/components/PhaseDirectionSelect/PhaseDirectionSelect.vue +126 -126
  268. package/src/kisscomps/components/PhaseDirectionText/PhaseDirectionText.vue +106 -106
  269. package/src/kisscomps/components/PhaseLegend/PhaseLegend.vue +286 -286
  270. package/src/kisscomps/components/PhaseMarker/index.js +6 -6
  271. package/src/kisscomps/components/PhaseMarker/phasemarker.vue +215 -215
  272. package/src/kisscomps/components/PhaseMarker/svg/patternSvg.vue +121 -121
  273. package/src/kisscomps/components/PhaseMarker/svg/phase.vue +60 -60
  274. package/src/kisscomps/components/PhaseMarker/svg/phaseCount.vue +62 -62
  275. package/src/kisscomps/components/PhaseMarker/svg/phaseCountCycle.vue +62 -62
  276. package/src/kisscomps/components/PhaseMarker/svg/phaseSvg.vue +117 -117
  277. package/src/kisscomps/components/PhasePedSelect/index.vue +206 -206
  278. package/src/kisscomps/components/SchemeConfig/azimuthlocking/index.vue +365 -365
  279. package/src/kisscomps/components/SchemeConfig/azimuthlocking/utils.js +92 -92
  280. package/src/kisscomps/components/SchemeConfig/closePhaselControlModal/index.vue +214 -214
  281. package/src/kisscomps/components/SchemeConfig/lockingPhaselControlModal/index.vue +235 -235
  282. package/src/kisscomps/components/SchemeConfig/manualControlModal/index.vue +235 -235
  283. package/src/kisscomps/components/SchemeConfig/manualControlModalNew/controlModelGroup.vue +131 -131
  284. package/src/kisscomps/components/SchemeConfig/manualControlModalNew/othersIcon.vue +151 -151
  285. package/src/kisscomps/components/SchemeConfig/priorityControl/index.vue +215 -215
  286. package/src/kisscomps/components/SchemeConfig/priorityControl/utils.js +163 -163
  287. package/src/kisscomps/components/SchemeConfig/utils/thirdPartypermission.js +95 -95
  288. package/src/kisscomps/components/StageOptimize/StageOptimize.vue +367 -367
  289. package/src/kisscomps/components/StageOptimize/index.js +2 -2
  290. package/src/kisscomps/components/StageStatus/StageStatus.vue +341 -341
  291. package/src/kisscomps/components/SvgIcon/SvgIcon.vue +53 -53
  292. package/src/kisscomps/components/XiaoKanban/DirSelector.vue +356 -356
  293. package/src/kisscomps/components/XiaoKanban/index.vue +122 -122
  294. package/src/kisscomps/components/patternConfig/pattern/planChart/model/coordinationModel.js +665 -665
  295. package/src/kisscomps/components/patternConfig/planContent.vue +604 -604
  296. package/src/kisscomps/components/patternConfig/planMenu.vue +329 -329
  297. package/src/lib/publicjs/ArryListUtil.js +38 -38
  298. package/src/lib/publicjs/HttpurlMgr.js +45 -45
  299. package/src/lib/publicjs/KissApi.js +158 -158
  300. package/src/lib/publicjs/KissWSSub/Heartcheck.js +128 -128
  301. package/src/lib/publicjs/KissWSSub/KissWsSub.js +91 -91
  302. package/src/lib/publicjs/KissWSSub/KissWsSubByType.js +152 -152
  303. package/src/lib/publicjs/KissWSSub/SimuWsSubByType.js +44 -44
  304. package/src/lib/publicjs/KissWSSub/Sub.js +51 -51
  305. package/src/lib/publicjs/KissWSSub/SubChannel.js +119 -119
  306. package/src/lib/publicjs/basecomponents.js +65 -65
  307. package/src/lib/publicjs/localStorage.js +112 -112
  308. package/src/lib/publicjs/objdeepcopy.js +32 -32
  309. package/src/lib/publicjs/pageScroll.js +30 -30
  310. package/src/lib/publicjs/passwdAssest.js +101 -101
  311. package/src/lib/publicjs/styleclassfactory.js +32 -32
  312. package/src/node_modules/.package_versions.json +1 -0
  313. package/src/store/index.js +26 -26
  314. package/src/store/modules/globalParam.js +67 -67
  315. package/src/utils/RingDataModel.js +335 -335
  316. package/src/utils/conflictList.js +87 -87
  317. package/src/utils/dateFormat.js +41 -41
  318. package/src/utils/index.js +69 -69
  319. package/src/utils/phaseList.js +203 -203
  320. package/src/utils/validate.js +43 -43
  321. package/src/views/home.1.vue +479 -479
  322. package/src/views/home.vue +93 -93
  323. package/static/styles/channelizatioon.scss +433 -433
  324. package/static/styles/common.scss +30 -30
  325. package/static/styles/commonkanban.scss +168 -168
  326. package/static/styles/dark/index.scss +2 -2
  327. package/static/styles/dark/theme/element-dark.scss +44 -44
  328. package/static/styles/index.scss +84 -84
  329. package/static/styles/intersection.scss +180 -180
  330. package/static/styles/light/index.scss +2 -2
  331. package/static/styles/light/theme/element-light.scss +44 -44
  332. package/static/styles/patternConfig.scss +56 -56
  333. package/static/styles/phasePedSelect.scss +71 -71
  334. package/static/styles/stages.scss +57 -57
  335. package/static/styles/xiaokanban.scss +61 -61
  336. package/static/token.json +2 -2
  337. package/test/e2e/custom-assertions/elementCount.js +27 -27
  338. package/test/e2e/nightwatch.conf.js +46 -46
  339. package/test/e2e/runner.js +48 -48
  340. package/test/e2e/specs/test.js +19 -19
  341. package/test/unit/.eslintrc +7 -7
  342. package/test/unit/jest.conf.js +30 -30
  343. package/test/unit/setup.js +3 -3
  344. package/test/unit/specs/HelloWorld.spec.js +11 -11
  345. package/package/kissui.js +0 -216608
  346. package/pnpm-lock.yaml +0 -16362
@@ -0,0 +1,369 @@
1
+ /**
2
+ * Copyright (c) 2020 kedacom
3
+ * OpenATC is licensed under Mulan PSL v2.
4
+ * You can use this software according to the terms and conditions of the Mulan PSL v2.
5
+ * You may obtain a copy of Mulan PSL v2 at:
6
+ * http://license.coscl.org.cn/MulanPSL2
7
+ * THIS SOFTWARE IS PROVIDED ON AN "AS IS" BASIS, WITHOUT WARRANTIES OF ANY KIND,
8
+ * EITHER EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO NON-INFRINGEMENT,
9
+ * MERCHANTABILITY OR FIT FOR A PARTICULAR PURPOSE.
10
+ * See the Mulan PSL v2 for more details.
11
+ **/
12
+ <template>
13
+ <div class="kanbanOptimize">
14
+ <div v-if="this.nowNumber === 1" class="optimizetype">
15
+ <span>{{$t('openatccomponents.pattern.optimizetype')}}</span>
16
+ <el-select v-model="value" clearable :placeholder="$t('openatccomponents.common.select')">
17
+ <el-option
18
+ v-for="item in typeOptions"
19
+ :key="item.value"
20
+ :label="$t('openatccomponents.overview.type' + item.value)"
21
+ :value="item.value"
22
+ >
23
+ </el-option>
24
+ </el-select>
25
+ <span class="optimiNum">{{$t('openatccomponents.pattern.optimizecycle')}}</span>
26
+ <el-input v-model="optimizecycle" clearable :placeholder="$t('openatccomponents.common.enter')"></el-input>
27
+ <!-- <el-button type="primary" @click="onOptimizeClick()">{{$t('openatccomponents.pattern.inoptimize')}}</el-button> -->
28
+ </div>
29
+ <div class="common-board-column" :style="{marginTop:this.nowNumber === 1 ? 0 : '50px',marginLeft:this.nowNumber === 1 ? 0 : 0}">
30
+ <div class="common-board-column-header">
31
+ {{headerText}}
32
+ </div>
33
+ <div class="openatccomponents-board-table-header">
34
+ <el-row :gutter="13">
35
+ <el-col :span="4">{{this.$t('openatccomponents.overview.phase')}}
36
+ </el-col>
37
+ <el-col :span="10">{{this.$t('openatccomponents.overview.flow')}}
38
+ </el-col>
39
+ <el-col :span="10">{{this.$t('openatccomponents.overview.saturationflow')}}
40
+ </el-col>
41
+ </el-row>
42
+ </div>
43
+ <draggable
44
+ class="common-board-column-content"
45
+ :list="list"
46
+ :options="options">
47
+ <div class="common-board-item" v-for="element in list" :key="element.id">
48
+ <el-row :gutter="13">
49
+ <el-col :span="4">
50
+ <el-tooltip class="item" effect="dark" placement="left">
51
+ <div slot="content">{{element.name}}</div>
52
+ <div class="common-phase-description">
53
+ <xdrdirselector Width="70px" Height="70px" Widths="58px" Heights="58px" :Datas="styles" :Data="showStyle" :showlist="element.desc" :ISActiveMask="ISActiveMask" :MaskColor="MaskColor"></xdrdirselector>
54
+ </div>
55
+ </el-tooltip>
56
+ </el-col>
57
+ <el-col :span="10">
58
+ <el-input-number :controls="false" class="col-content" size="small" :step="1" v-model.number="element.flowperhour" ref="type" :disabled="element.mode === 7"></el-input-number>
59
+ </el-col>
60
+ <el-col :span="10">
61
+ <el-input-number :controls="false" class="col-content" size="small" :step="1" v-model.number="element.saturation" ref="types" :disabled="element.mode === 7"></el-input-number>
62
+ </el-col>
63
+ </el-row>
64
+ </div>
65
+ </draggable>
66
+ </div>
67
+ </div>
68
+ </template>
69
+ <script>
70
+ import draggable from 'vuedraggable'
71
+ import { getDuration } from '@/api/cross'
72
+ import xdrdirselector from '@/components/XRDDirSelector'
73
+
74
+ export default {
75
+ name: 'patternOptimize',
76
+ components: {
77
+ draggable,
78
+ xdrdirselector
79
+ },
80
+ data () {
81
+ return {
82
+ showStyle: {
83
+ left: '7px',
84
+ top: '0px'
85
+ },
86
+ styles: {
87
+ left: '7px',
88
+ top: '0px'
89
+ },
90
+ typeOptions: [{
91
+ value: 'flow-split-opt'
92
+ }, {
93
+ value: 'cycle-opt'
94
+ }],
95
+ value: 'flow-split-opt',
96
+ optimizecycle: 0
97
+ }
98
+ },
99
+ props: {
100
+ headerText: {
101
+ type: String,
102
+ default: 'Header'
103
+ },
104
+ id: {
105
+ type: Number
106
+ },
107
+ rings: {
108
+ type: Array
109
+ },
110
+ nowNumber: {
111
+ type: Number
112
+ },
113
+ phaseList: {
114
+ type: Array
115
+ },
116
+ options: {
117
+ type: Object,
118
+ default () {
119
+ return {}
120
+ }
121
+ },
122
+ list: {
123
+ type: Array,
124
+ default () {
125
+ return []
126
+ }
127
+ },
128
+ // index: {
129
+ // type: Number
130
+ // },
131
+ ISActiveMask: {
132
+ type: Boolean,
133
+ default: true
134
+ },
135
+ // 当phase的描述为空时,显示的图形颜色。
136
+ MaskColor: {
137
+ type: String,
138
+ default: '#000000'
139
+ }
140
+ },
141
+ created () {
142
+ // this.addMinSplit()
143
+ this.addMin()
144
+ },
145
+ computed () {
146
+
147
+ },
148
+ watch: {
149
+ list: {
150
+ handler: function () {
151
+ // let list = this.$refs.type
152
+ // let flow = this.$refs.types
153
+ // console.log(this.list, 'list')
154
+ // let cycle = 0
155
+ // let n = this.index
156
+ // for (let i = 0; i < list.length; i++) {
157
+ // cycle = cycle + Number(list[i].currentValue)
158
+ // }
159
+ // const globalParamModel = this.$store.getters.globalParamModel
160
+ // // let MaxCycle = globalParamModel.getParamsByType('patternList')[n].cycle
161
+ // let pattern = globalParamModel.getParamsByType('patternList')[n]
162
+ // globalParamModel.getParamsByType('patternList')[n].cycle = this.getMaxCycle(pattern)
163
+ // this.addMinSplit()
164
+ // this.$emit('handleSplit', n)
165
+ },
166
+ deep: true
167
+ }
168
+ },
169
+ methods: {
170
+ onOptimizeClick () {
171
+ let msg = this.$t('openatccomponents.pattern.algorithmEngineOptimization')
172
+ const loading = this.$loading({
173
+ lock: true,
174
+ text: msg,
175
+ spinner: 'el-icon-loading',
176
+ background: 'rgba(0, 0, 0, 0.7)'
177
+ })
178
+ setTimeout(() => {
179
+ loading.close()
180
+ this.handeleOptimizeClick()
181
+ }, 1000)
182
+ },
183
+ handeleOptimizeClick () {
184
+ let newPha = []
185
+ for (let i = 0; i < this.rings.length; i++) {
186
+ newPha.push(...this.rings[i])
187
+ }
188
+ let phaseData = newPha.map(item => {
189
+ return {
190
+ id: item.id,
191
+ flowperhour: item.flowperhour,
192
+ saturation: item.saturation
193
+ }
194
+ })
195
+ let patternList = this.$store.state.globalParam.tscParam.patternList
196
+ let pattern = patternList.filter((item) => item.id === this.id)[0]
197
+ let reqData = {
198
+ 'type': this.value,
199
+ 'optcycle': this.optimizecycle ? this.optimizecycle : 0,
200
+ 'phaseList': this.phaseList,
201
+ 'pattern': pattern,
202
+ 'phases': phaseData
203
+ }
204
+ let isValidata = []
205
+ for (let j = 0; j < newPha.length; j++) {
206
+ let comNum = (newPha[j].length / 4) * 1700 * 0.8
207
+ isValidata.push(newPha[j].flowperhour > comNum)
208
+ }
209
+ if (isValidata.includes(true)) {
210
+ this.$confirm(this.$t('openatccomponents.overview.maxFlow'),
211
+ this.$t('openatccomponents.common.alarm'), {
212
+ confirmButtonText: this.$t('eopenatccomponentsdge.common.confirm'),
213
+ cancelButtonText: this.$t('openatccomponents.common.cancel'),
214
+ type: 'warning'
215
+ }).then(() => {
216
+ getDuration(reqData).then(data => {
217
+ if (data.data.success) {
218
+ this.$message({
219
+ type: 'success',
220
+ message: this.$t('openatccomponents.pattern.success')
221
+ })
222
+ for (let i = 0; i < this.rings.length; i++) {
223
+ for (let j = 0; j < this.rings[i].length; j++) {
224
+ for (let h = 0; h < data.data.data.phase.length; h++) {
225
+ if (this.rings[i][j].id === data.data.data.phase[h].id) {
226
+ this.rings[i][j].value = data.data.data.phase[h].duration
227
+ // this.rings[i][j].cycle = data.data.data.phase[h].cycle
228
+ }
229
+ }
230
+ }
231
+ }
232
+ }
233
+ }).catch(error => {
234
+ console.log(error)
235
+ })
236
+ }).catch(() => {
237
+ })
238
+ } else {
239
+ getDuration(reqData).then(data => {
240
+ if (data.data.success) {
241
+ this.$message({
242
+ type: 'success',
243
+ message: this.$t('openatccomponents.pattern.success')
244
+ })
245
+ for (let i = 0; i < this.rings.length; i++) {
246
+ for (let j = 0; j < this.rings[i].length; j++) {
247
+ for (let h = 0; h < data.data.data.phase.length; h++) {
248
+ if (this.rings[i][j].id === data.data.data.phase[h].id) {
249
+ this.rings[i][j].value = data.data.data.phase[h].duration
250
+ // this.rings[i][j].cycle = data.data.data.phase[h].cycle
251
+ }
252
+ }
253
+ }
254
+ }
255
+ }
256
+ }).catch(error => {
257
+ console.log(error)
258
+ })
259
+ }
260
+ },
261
+ addMin () {
262
+ for (let i of this.list) {
263
+ if (!i.flowperhour || !i.saturation) {
264
+ i.length = this.list.length
265
+ i.flowperhour = 0
266
+ i.saturation = 1700
267
+ }
268
+ }
269
+ }
270
+ // addMinSplit () {
271
+ // const globalParamModel = this.$store.getters.globalParamModel
272
+ // let phaseList = globalParamModel.getParamsByType('phaseList')
273
+ // for (let ls of this.list) {
274
+ // let phase = phaseList.filter((item) => {
275
+ // return item.id === ls.id
276
+ // })[0]
277
+ // if (!phase.redyellow) {
278
+ // phase.redyellow = 0
279
+ // }
280
+ // if (!phase.yellow) {
281
+ // phase.yellow = 0
282
+ // }
283
+ // if (!phase.redclear) {
284
+ // phase.redclear = 0
285
+ // }
286
+ // if (!phase.flashgreen) {
287
+ // phase.flashgreen = 0
288
+ // }
289
+ // if (!phase.phasewalk) {
290
+ // phase.phasewalk = 0
291
+ // }
292
+ // if (!phase.pedclear) {
293
+ // phase.pedclear = 0
294
+ // }
295
+ // // let temp1 = phase.redyellow + phase.yellow + phase.redclear + phase.flashgreen // 绿信比的最小值要大于最小绿+黄灯+全红+绿闪
296
+ // // let temp2 = phase.phasewalk + phase.pedclear
297
+ // // if (temp1 > temp2) {
298
+ // // ls.minSplit = temp1
299
+ // // } else {
300
+ // // ls.minSplit = temp2
301
+ // // }
302
+ // // if (ls.mode !== 7 && ls.value < ls.minSplit) {
303
+ // // ls.value = ls.minSplit
304
+ // // }
305
+ // // let temp1 = phase.yellow + phase.redclear + phase.flashgreen // 绿信比的最小值要大于最小绿+黄灯+全红+绿闪
306
+ // let temp1 = phase.yellow + phase.redclear + phase.mingreen
307
+ // let temp2 = phase.yellow + phase.redclear + phase.phasewalk + phase.pedclear
308
+ // ls.minSplit = temp1 > temp2 ? temp1 : temp2
309
+ // if (ls.mode !== 7 && ls.value < ls.minSplit) {
310
+ // ls.value = ls.minSplit
311
+ // this.$message.error(this.$t('openatccomponents.pattern.splitCheckMsg'))
312
+ // }
313
+ // }
314
+ // },
315
+ // getMaxCycle (pattern) {
316
+ // let rings = pattern.rings
317
+ // let maxCycle = 0
318
+ // for (let ring of rings) {
319
+ // if (ring.length === 0) continue
320
+ // let cycle = 0
321
+ // for (let r of ring) {
322
+ // if (r.mode === 7) { // 忽略相位不计周期
323
+ // continue
324
+ // }
325
+ // cycle = cycle + r.value
326
+ // }
327
+ // if (cycle > maxCycle) {
328
+ // maxCycle = cycle
329
+ // }
330
+ // }
331
+ // return maxCycle
332
+ // },
333
+ // doChange (val) {
334
+ // // if (val.mode === 7) {
335
+ // // val.value = 0
336
+ // // } else {
337
+ // // val.value = 30
338
+ // // }
339
+ // }
340
+ }
341
+ }
342
+ </script>
343
+ <style lang="scss" scoped>
344
+ .col-content {
345
+ width: 100%;
346
+ }
347
+ .kanbanOptimize {
348
+ .common-board-column {
349
+ max-width: unset !important;
350
+ }
351
+ }
352
+ .optimizetype{
353
+ // float: left;
354
+ font-size: 14PX;
355
+ margin:0 0 10PX 0;
356
+ .el-input {
357
+ width: 80PX;
358
+ }
359
+ .el-select{
360
+ width: 145PX;
361
+ }
362
+ .el-button {
363
+ margin-left: 10PX;
364
+ }
365
+ .optimiNum {
366
+ padding-left: 10PX;
367
+ }
368
+ }
369
+ </style>
@@ -39,8 +39,47 @@
39
39
  </div>
40
40
  </el-tooltip>
41
41
  </div>
42
- <div class="first-1" :style="{'width':item.greenWidth,'height':'34px','background':'#7ccc66'}"></div>
43
- <div class="first-1" :style="{'width':item.redWidth,'height':'17px',marginTop: '9px','background':'#f27979'}"></div>
42
+ <!-- 晚启动(lategreen)产生的头部红灯 -->
43
+ <div
44
+ v-if="item.headRedWidth && item.headRedWidth !== '0%'"
45
+ class="first-1"
46
+ :style="{
47
+ width: item.headRedWidth,
48
+ marginTop: '9px',
49
+ height: '17px',
50
+ background: '#f27979',
51
+ }"
52
+ ></div>
53
+ <!-- 主体绿灯(可能已被 leadinggreen / lategreen 削减) -->
54
+ <div
55
+ class="first-1"
56
+ :style="{
57
+ width: item.greenWidth,
58
+ height: '34px',
59
+ background: '#7ccc66',
60
+ }"
61
+ ></div>
62
+ <!-- 早结束(leadinggreen)产生的尾部红灯 -->
63
+ <div
64
+ v-if="item.tailRedWidth && item.tailRedWidth !== '0%'"
65
+ class="first-1"
66
+ :style="{
67
+ width: item.tailRedWidth,
68
+ marginTop: '9px',
69
+ height: '17px',
70
+ background: '#f27979',
71
+ }"
72
+ ></div>
73
+ <!-- 非重叠阶段或剩余红灯时间 -->
74
+ <div
75
+ class="first-1"
76
+ :style="{
77
+ width: item.redWidth,
78
+ height: '17px',
79
+ marginTop: '9px',
80
+ background: '#f27979',
81
+ }"
82
+ ></div>
44
83
  </div>
45
84
  </div>
46
85
  </div>
@@ -73,6 +112,9 @@ export default {
73
112
  stageList: {
74
113
  type: Array
75
114
  },
115
+ patternoverlaplist: {
116
+ type: Array
117
+ },
76
118
  checked: {
77
119
  type: Boolean
78
120
  },
@@ -112,6 +154,13 @@ export default {
112
154
  },
113
155
  // 深度观察监听
114
156
  deep: true
157
+ },
158
+ patternoverlaplist: {
159
+ handler: function (val, oldVal) {
160
+ this.doAdd(this.stageList, this.overlap)
161
+ },
162
+ // 深度观察监听
163
+ deep: true
115
164
  }
116
165
  },
117
166
  created () {
@@ -160,15 +209,28 @@ export default {
160
209
  },
161
210
  doAdd (stageList, overlap) { // 阶段显示颜色
162
211
  let overlapData = overlap.map(item => {
212
+ // 若 patternoverlaplist 中有对应项且带 includedPhases,则用其参与计算的相位;否则用 overlap 的 includedphases
213
+ const overlapPattern =
214
+ Array.isArray(this.patternoverlaplist) &&
215
+ this.patternoverlaplist.find(p => p.id === item.id)
216
+ const includedPhases = overlapPattern &&
217
+ Array.isArray(overlapPattern.includedPhases) &&
218
+ (overlapPattern.includedPhases).length > 0
219
+ ? (overlapPattern.includedPhases)
220
+ : (item.includedphases || [])
221
+ const modifyPhases = overlapPattern &&
222
+ Array.isArray(overlapPattern.modifyphase)
223
+ ? overlapPattern.modifyphase
224
+ : (item.modifyphase !== undefined ? item.modifyphase : [])
163
225
  let findIndexs = []
164
- item.includedphases.forEach(i => {
165
- const findItems = stageList.filter(j => (j.phases ? j.phases : j.stages).includes(i))
226
+ includedPhases.forEach(i => {
227
+ const findItems = stageList.filter(j => j.phases.includes(i))
166
228
  if (findItems.length) findIndexs.push(...findItems.map(m => m.key))
167
229
  })
168
230
  // 收集所有包含 modifyphase 中相位的阶段 key
169
231
  let modifyIndexs = []
170
- if (item.modifyphase !== undefined) {
171
- item.modifyphase.forEach(i => {
232
+ if (modifyPhases.length > 0) {
233
+ modifyPhases.forEach(i => {
172
234
  const findItems = stageList.filter(j => j.phases.includes(i))
173
235
  if (findItems.length) modifyIndexs.push(...findItems.map(m => m.key))
174
236
  })
@@ -184,18 +246,75 @@ export default {
184
246
  } else {
185
247
  this.max = ''
186
248
  }
249
+
250
+ // 读取当前 overlap 对应的晚启动 / 早结束时间(单位与 split 一致,overlapPattern 已在上方根据 item.id 取过)
251
+ let lategreen = overlapPattern && typeof overlapPattern.lategreen === 'number'
252
+ ? overlapPattern.lategreen
253
+ : 0
254
+ let leadinggreen = overlapPattern && typeof overlapPattern.leadinggreen === 'number'
255
+ ? overlapPattern.leadinggreen
256
+ : 0
257
+
258
+ // 按阶段初始化绿灯 / 红灯时长(单位:split)
259
+ const stageTimeMap = {}
260
+ stageList.forEach(sta => {
261
+ const inOverlap = findIndexs.includes(sta.key) && !modifyIndexs.includes(sta.key)
262
+ stageTimeMap[sta.key] = {
263
+ green: inOverlap ? sta.split : 0, // 重叠阶段默认全绿
264
+ red: inOverlap ? 0 : sta.split, // 非重叠阶段全红(底部红条)
265
+ headRed: 0, // 晚启动(lategreen)拆出来的头部红
266
+ tailRed: 0 // 早结束(leadinggreen)拆出来的尾部红
267
+ }
268
+ })
269
+
270
+ // 处理晚启动:从头到尾,优先削减最前面的绿灯,生成 headRed
271
+ let remainLate = lategreen
272
+ if (remainLate > 0) {
273
+ stageList.forEach(sta => {
274
+ if (remainLate <= 0) return
275
+ const cur = stageTimeMap[sta.key]
276
+ if (!cur || cur.green <= 0) return
277
+ const cut = Math.min(cur.green, remainLate)
278
+ cur.green -= cut
279
+ cur.headRed += cut
280
+ remainLate -= cut
281
+ })
282
+ }
283
+
284
+ // 处理早结束:从尾到头,优先削减最后面的绿灯,生成 tailRed
285
+ let remainLead = leadinggreen
286
+ if (remainLead > 0) {
287
+ ;[...stageList].reverse().forEach(sta => {
288
+ if (remainLead <= 0) return
289
+ const cur = stageTimeMap[sta.key]
290
+ if (!cur || cur.green <= 0) return
291
+ const cut = Math.min(cur.green, remainLead)
292
+ cur.green -= cut
293
+ cur.tailRed += cut
294
+ remainLead -= cut
295
+ })
296
+ }
297
+
298
+ const totalCycle = (this.max ? this.max : this.cycle)
299
+
187
300
  return {
188
301
  ...item,
189
302
  peddirection: this.getPedPhasePos(item.peddirection),
190
303
  sidewalkPhaseData: this.getPedPhasePos(item.peddirection),
191
304
  stageLists: stageList.map(sta => {
192
- const find = findIndexs.includes(sta.key) && !modifyIndexs.includes(sta.key)
305
+ const t = stageTimeMap[sta.key] || { green: 0, red: sta.split, headRed: 0, tailRed: 0 }
306
+ const scale = totalCycle || 1
307
+ const greenWidth = (t.green / scale * 100).toFixed(3) + '%'
308
+ const redWidth = (t.red / scale * 100).toFixed(3) + '%'
309
+ const headRedWidth = (t.headRed / scale * 100).toFixed(3) + '%'
310
+ const tailRedWidth = (t.tailRed / scale * 100).toFixed(3) + '%'
193
311
  return {
194
312
  ...sta,
195
313
  direction: this.getRoad(item),
196
- // peddirection: this.getPedPhasePos(item.peddirection),
197
- greenWidth: find ? (sta.split / (this.max ? this.max : this.cycle) * 100).toFixed(3) + '%' : '0%',
198
- redWidth: !find ? (sta.split / (this.max ? this.max : this.cycle) * 100).toFixed(3) + '%' : '0%'
314
+ headRedWidth,
315
+ greenWidth,
316
+ tailRedWidth,
317
+ redWidth
199
318
  }
200
319
  })
201
320
  }
@@ -210,7 +329,7 @@ export default {
210
329
  .ring-first {
211
330
  // margin-top: 1px;
212
331
  width: 100%;
213
- height: 34px;
332
+ height: 40px;
214
333
  .first-1 {
215
334
  float: left;
216
335
  margin-top: 1px;