openatc-components 0.4.89 → 0.4.90

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.
package/config/index.js CHANGED
@@ -15,7 +15,7 @@
15
15
  const fs = require('fs');
16
16
  const path = require('path')
17
17
  let VUE_APP_PROXY_API_TARGET = "http://127.0.0.1:8080"
18
- let VUE_APP_PROXY_MAIN_TARGET = "http://192.168.14.122:10003/openatc"
18
+ let VUE_APP_PROXY_MAIN_TARGET = "http://192.168.13.103:10003/openatc"
19
19
  let VUE_APP_PROXY_SOCKET_TARGET = "http://127.0.0.1:8080"
20
20
  const localFile = path.resolve(__dirname, 'dev.local.js');
21
21
  if (fs.existsSync(localFile)) {
@@ -31,7 +31,7 @@
31
31
  <!-- 右行道路 B-->
32
32
  <div class="right-dir-road" v-if="roadDir === 'right'">
33
33
  <div class="centerText" v-if="crossType !== 'Customroads' && isHasPhase">
34
- <div class="merge-direction-icon">
34
+ <div v-if="isVipRoute" class="merge-direction-icon">
35
35
  <xdr-dir-selector
36
36
  :Data="xdrMData"
37
37
  Width="80px"
@@ -888,11 +888,13 @@ export default {
888
888
  this.getMergeDirections()
889
889
  }
890
890
  if (this.isVipRoute && !this.isThirdSignal && !this.isRcp) {
891
+ alert('1')
891
892
  // 特勤、分组管控下,非第三方设备且不是rcp协议,按通道显示相位方向;第三方设备和rcp协议还是按路口相位配置显示相位方向
892
893
  this.getChannelInfo()
893
894
  return
894
895
  }
895
896
  if (this.channelType && !this.isThirdSignal) {
897
+ alert('2')
896
898
  this.getChannelInfo()
897
899
  return
898
900
  }
@@ -936,6 +938,7 @@ export default {
936
938
  this.drawDefaultPhaseIcon()
937
939
  }
938
940
  if ((this.isVipRoute && this.isThirdSignal) || (this.isVipRoute && this.isRcp)) {
941
+ alert('3')
939
942
  this.LanePhaseData = this.CrossDiagramMgr.compare(this.LanePhaseData, this.overlapLanePhaseData, 'type', 'nostatus')
940
943
  // console.log(this.LanePhaseData)
941
944
  this.sidewalkPhaseData = this.CrossDiagramMgr.compare(this.sidewalkPhaseData, this.overlapsidewalkPhaseData, 'pedtype', 'nostatus')
@@ -1367,6 +1370,7 @@ export default {
1367
1370
  const targetIds = [4, 8, 12, 16] // 掉头相位后画
1368
1371
  this.LanePhaseData = this.LanePhaseData.filter(item => !targetIds.includes(item.id)).concat(this.LanePhaseData.filter(item => targetIds.includes(item.id)))
1369
1372
  if (!this.isThirdSignal && this.isVipRoute && !this.isRcp) {
1373
+ alert('4')
1370
1374
  await this.getConflictList()
1371
1375
  this.handleClickedPhase()
1372
1376
  this.compLanePhaseData = JSON.parse(JSON.stringify(this.LanePhaseData))
@@ -688,11 +688,6 @@ export default {
688
688
  color: #299BCC;
689
689
  margin-top: 20PX;
690
690
  }
691
- .merge-direction-icon {
692
- width: 80PX;
693
- height: 80PX;
694
- margin: 0 auto;
695
- }
696
691
 
697
692
  .baseImg {
698
693
  width: 100%;
@@ -10,6 +10,12 @@
10
10
  <span v-for="(ids,index3) in list.includedphases" :key="index3">
11
11
  {{$t('openatccomponents.phase.phase')}}{{ids}}<span v-if="index3+1!==list.includedphases.length">,</span>
12
12
  </span>
13
+ <span v-if="list.modifyphase && list.modifyphase.length>0">(<span v-for="(ids, index4) in list.modifyphase" :key="index4">
14
+ *{{$t('openatccomponents.phase.phase')}}{{ ids
15
+ }}<span v-if="index4 + 1 !== list.modifyphase.length"
16
+ >,</span
17
+ >
18
+ </span>)</span>
13
19
  </div>
14
20
  <div style="cursor:pointer;">
15
21
  <div class="ring-phase">
@@ -22,6 +28,12 @@
22
28
  <span v-for="(ids,index3) in list.includedphases" :key="index3">
23
29
  {{$t('openatccomponents.phase.phase')}}{{ids}}<span v-if="index3+1!==list.includedphases.length">,</span>
24
30
  </span>
31
+ <span v-if="list.modifyphase && list.modifyphase.length>0">(<span v-for="(ids, index4) in list.modifyphase" :key="index4">
32
+ *{{$t('openatccomponents.phase.phase')}}{{ ids
33
+ }}<span v-if="index4 + 1 !== list.modifyphase.length"
34
+ >,</span
35
+ >
36
+ </span>)</span>
25
37
  </div>
26
38
  </div>
27
39
  </div>
@@ -153,7 +165,16 @@ export default {
153
165
  const findItems = stageList.filter(j => (j.phases ? j.phases : j.stages).includes(i))
154
166
  if (findItems.length) findIndexs.push(...findItems.map(m => m.key))
155
167
  })
168
+ // 收集所有包含 modifyphase 中相位的阶段 key
169
+ let modifyIndexs = []
170
+ if (item.modifyphase !== undefined) {
171
+ item.modifyphase.forEach(i => {
172
+ const findItems = stageList.filter(j => j.phases.includes(i))
173
+ if (findItems.length) modifyIndexs.push(...findItems.map(m => m.key))
174
+ })
175
+ }
156
176
  findIndexs = Array.from(new Set(findIndexs))
177
+ modifyIndexs = Array.from(new Set(modifyIndexs))
157
178
  if (this.cycleChange) {
158
179
  const globalParamModel = this.$store.getters.globalParamModel
159
180
  let pattern = globalParamModel.getParamsByType('patternList')
@@ -168,7 +189,7 @@ export default {
168
189
  peddirection: this.getPedPhasePos(item.peddirection),
169
190
  sidewalkPhaseData: this.getPedPhasePos(item.peddirection),
170
191
  stageLists: stageList.map(sta => {
171
- const find = findIndexs.includes(sta.key)
192
+ const find = findIndexs.includes(sta.key) && !modifyIndexs.includes(sta.key)
172
193
  return {
173
194
  ...sta,
174
195
  direction: this.getRoad(item),
@@ -837,6 +837,20 @@ export default {
837
837
  let addRing1 = [...new Set(resultArrs[1])].filter(item => newCurrent[h].includes(item))
838
838
  ring1s.push(addRing1)
839
839
  }
840
+ // 双环相位数不等的时候
841
+ if (newRings.length > 1) {
842
+ if (newRings[0].length !== newRings[1].length) {
843
+ for (let h = 0; h < newCurrent.length; h++) {
844
+ let adds = [...new Set(ringsequence[0])].filter(item => newCurrent[h].includes(item))
845
+ ring1.push(adds)
846
+ }
847
+ let ring1s = [] // 环1与关系2的并集
848
+ for (let h = 0; h < newCurrent.length; h++) {
849
+ let addRing1 = [...new Set(ringsequence[1])].filter(item => newCurrent[h].includes(item))
850
+ ring1s.push(addRing1)
851
+ }
852
+ }
853
+ }
840
854
  barrierRing1.push(...ring1, ...ring1s)
841
855
  let resultList = []
842
856
  if (newRings.length > 1) {
@@ -1123,6 +1137,20 @@ export default {
1123
1137
  let addRing1 = [...new Set(resultArrs[1])].filter(item => newCurrent[h].includes(item))
1124
1138
  ring1s.push(addRing1)
1125
1139
  }
1140
+ // 双环相位数不等的时候
1141
+ if (newRings.length > 1) {
1142
+ if (newRings[0].length !== newRings[1].length) {
1143
+ for (let h = 0; h < newCurrent.length; h++) {
1144
+ let adds = [...new Set(ringsequence[0])].filter(item => newCurrent[h].includes(item))
1145
+ ring1.push(adds)
1146
+ }
1147
+ let ring1s = [] // 环1与关系2的并集
1148
+ for (let h = 0; h < newCurrent.length; h++) {
1149
+ let addRing1 = [...new Set(ringsequence[1])].filter(item => newCurrent[h].includes(item))
1150
+ ring1s.push(addRing1)
1151
+ }
1152
+ }
1153
+ }
1126
1154
  barrierRing1.push(...ring1, ...ring1s)
1127
1155
  let resultList = []
1128
1156
  if (newRings.length > 1) {
@@ -1372,6 +1400,20 @@ export default {
1372
1400
  let addRing1 = [...new Set(resultArrs[1])].filter(item => newCurrent[h].includes(item))
1373
1401
  ring1s.push(addRing1)
1374
1402
  }
1403
+ // 双环相位数不等的时候
1404
+ if (newRings.length > 1) {
1405
+ if (newRings[0].length !== newRings[1].length) {
1406
+ for (let h = 0; h < newCurrent.length; h++) {
1407
+ let adds = [...new Set(ringsequence[0])].filter(item => newCurrent[h].includes(item))
1408
+ ring1.push(adds)
1409
+ }
1410
+ let ring1s = [] // 环1与关系2的并集
1411
+ for (let h = 0; h < newCurrent.length; h++) {
1412
+ let addRing1 = [...new Set(ringsequence[1])].filter(item => newCurrent[h].includes(item))
1413
+ ring1s.push(addRing1)
1414
+ }
1415
+ }
1416
+ }
1375
1417
  barrierRing1.push(...ring1, ...ring1s)
1376
1418
  let resultList = []
1377
1419
  if (newRings.length >= 1) {
@@ -1430,9 +1472,6 @@ export default {
1430
1472
  if (this.patternList) {
1431
1473
  this.setBarrier(ringTeams, val)
1432
1474
  }
1433
- if (newRings.length > 1) {
1434
- this.fillGap(ringTeams, val)
1435
- }
1436
1475
  if (this.cycleChange) {
1437
1476
  const globalParamModel = this.$store.getters.globalParamModel
1438
1477
  let pattern = globalParamModel.getParamsByType('patternList')
@@ -1442,6 +1481,9 @@ export default {
1442
1481
  } else {
1443
1482
  this.max = ''
1444
1483
  }
1484
+ if (newRings.length > 1) {
1485
+ this.fillGap(ringTeams, val)
1486
+ }
1445
1487
  let barrier = this.step2(ringTeams, newPattern)
1446
1488
  let barrierLeft = barrier.map(item => item)// 屏障左移显示出人行横道
1447
1489
  this.barrierList = barrierLeft.map(j => {
@@ -441,7 +441,11 @@ PURPOSE. * See the Mulan PSL v2 for more details. **/
441
441
  :width="iconWidth"
442
442
  :height="iconHeight"
443
443
  >
444
- <path d="M947.685353 711.851301h-34.260223v-121.814126c0-15.226766-11.420074-30.453532-30.453531-30.453532h-342.602231v-167.494424h137.040892c38.066914 0 64.713755-30.453532 64.713755-64.713754V114.200743c0-38.066914-30.453532-64.713755-64.713755-64.713754H346.228104c-38.066914-3.806691-68.520446 26.64684-68.520446 64.713754v216.981413c0 38.066914 30.453532 64.713755 64.713755 64.713755h137.040892v167.494424h-342.602231c-15.226766 0-30.453532 11.420074-30.453531 30.453531v121.814127h-26.64684c-38.066914 0-64.713755 30.453532-64.713755 64.713754v137.040892c0 38.066914 30.453532 64.713755 64.713755 64.713755h137.040892c38.066914 0 64.713755-30.453532 64.713754-64.713755v-137.040892c0-38.066914-30.453532-64.713755-64.713754-64.713754H167.313606v-91.360595h315.95539v91.360595h-41.873606c-38.066914 0-64.713755 30.453532-64.713754 64.713754v137.040892c0 38.066914 30.453532 64.713755 64.713754 64.713755h137.040893c38.066914 0 64.713755-30.453532 64.713754-64.713755v-137.040892c0-38.066914-30.453532-64.713755-64.713754-64.713754h-41.873606v-91.360595H852.518067v91.360595h-45.680297c-38.066914 0-64.713755 30.453532-64.713755 64.713754v137.040892c0 38.066914 30.453532 64.713755 64.713755 64.713755h137.040892c38.066914 0 64.713755-30.453532 64.713754-64.713755v-137.040892c3.806691-38.066914-22.840149-68.520446-60.907063-68.520446z m7.613383 205.561338c0 3.806691-3.806691 7.613383-7.613383 7.613383h-137.040892c-3.806691 0-7.613383-3.806691-7.613383-7.613383v-137.040892c0-3.806691 3.806691-7.613383 7.613383-7.613383h137.040892c3.806691 0 7.613383 3.806691 7.613383 7.613383v137.040892z" p-id="21091"></path></svg>
444
+ <path
445
+ :class="themeColor"
446
+ d="M947.685353 711.851301h-34.260223v-121.814126c0-15.226766-11.420074-30.453532-30.453531-30.453532h-342.602231v-167.494424h137.040892c38.066914 0 64.713755-30.453532 64.713755-64.713754V114.200743c0-38.066914-30.453532-64.713755-64.713755-64.713754H346.228104c-38.066914-3.806691-68.520446 26.64684-68.520446 64.713754v216.981413c0 38.066914 30.453532 64.713755 64.713755 64.713755h137.040892v167.494424h-342.602231c-15.226766 0-30.453532 11.420074-30.453531 30.453531v121.814127h-26.64684c-38.066914 0-64.713755 30.453532-64.713755 64.713754v137.040892c0 38.066914 30.453532 64.713755 64.713755 64.713755h137.040892c38.066914 0 64.713755-30.453532 64.713754-64.713755v-137.040892c0-38.066914-30.453532-64.713755-64.713754-64.713754H167.313606v-91.360595h315.95539v91.360595h-41.873606c-38.066914 0-64.713755 30.453532-64.713754 64.713754v137.040892c0 38.066914 30.453532 64.713755 64.713754 64.713755h137.040893c38.066914 0 64.713755-30.453532 64.713754-64.713755v-137.040892c0-38.066914-30.453532-64.713755-64.713754-64.713754h-41.873606v-91.360595H852.518067v91.360595h-45.680297c-38.066914 0-64.713755 30.453532-64.713755 64.713754v137.040892c0 38.066914 30.453532 64.713755 64.713755 64.713755h137.040892c38.066914 0 64.713755-30.453532 64.713754-64.713755v-137.040892c3.806691-38.066914-22.840149-68.520446-60.907063-68.520446z m7.613383 205.561338c0 3.806691-3.806691 7.613383-7.613383 7.613383h-137.040892c-3.806691 0-7.613383-3.806691-7.613383-7.613383v-137.040892c0-3.806691 3.806691-7.613383 7.613383-7.613383h137.040892c3.806691 0 7.613383 3.806691 7.613383 7.613383v137.040892z" p-id="21091">
447
+ </path>
448
+ </svg>
445
449
  </span>
446
450
  </template>
447
451