openatc-components 0.4.86 → 0.4.87
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/package/kisscomps/components/BoardCard/BoardCard.vue +0 -4
- package/package/kisscomps/components/PatternStatus/PatternStatus.vue +1 -81
- package/package/kisscomps/components/patternList/patternList.vue +0 -4
- package/package/kisscomps/index.js +6 -2
- package/package/kissui.min.js +1 -1
- package/package.json +1 -1
- package/src/i18n/language/index.js +6 -0
- package/src/i18n/language/ru.js +1477 -0
- package/src/kisscomps/components/BoardCard/BoardCard.vue +0 -4
- package/src/kisscomps/components/PatternStatus/PatternStatus.vue +1 -81
- package/src/kisscomps/components/patternList/patternList.vue +0 -4
- package/src/kisscomps/index.js +6 -2
- package/src/views/patternConfig.vue +2 -2
- package/src/views/schemeconfig.vue +1 -1
|
@@ -15,7 +15,6 @@
|
|
|
15
15
|
:isMove="isMove"
|
|
16
16
|
:localPatternList="localPatternList"
|
|
17
17
|
:showCondition="showCondition"
|
|
18
|
-
:patternType="patternType"
|
|
19
18
|
:contrloType="contrloType"
|
|
20
19
|
:allPatternList="allPatternList"
|
|
21
20
|
:stagesChange="stagesChange"
|
|
@@ -104,9 +103,6 @@ export default {
|
|
|
104
103
|
patternId: {
|
|
105
104
|
type: Number
|
|
106
105
|
},
|
|
107
|
-
patternType: {
|
|
108
|
-
type: String
|
|
109
|
-
},
|
|
110
106
|
agentId: {
|
|
111
107
|
type: String
|
|
112
108
|
},
|
|
@@ -11,33 +11,8 @@
|
|
|
11
11
|
**/
|
|
12
12
|
<template>
|
|
13
13
|
<div class="main-patternstatus">
|
|
14
|
-
<!-- rcp模式 -->
|
|
15
|
-
<div v-if="patternType === 'rcp'">
|
|
16
|
-
<div class="ring-first" v-for="(list, index1) in patternRcp" :key="index1">
|
|
17
|
-
<div style="position: relative" :style="{height: '34px',paddingRight: '1px',float: 'left',width:
|
|
18
|
-
((item.split + (item.sum ? item.sum : 0)) /(item.cycle > cycles ? item.cycle : cycles)) *100 +'%',}"
|
|
19
|
-
v-for="(item, index2) in list" :key="index2">
|
|
20
|
-
<div class="first-1" :style="{ width:
|
|
21
|
-
(Number(item.greenWidth.replace('%', '')) /
|
|
22
|
-
Number((((item.split + (item.sum ? item.sum : 0)) /
|
|
23
|
-
(item.cycle > cycles ? item.cycle : cycles)) * 100 + '%').replace('%', ''))) * 100 + '%', height: '34px',background: '#7ccc66'}">
|
|
24
|
-
</div>
|
|
25
|
-
<el-tooltip placement="top-start" effect="light">
|
|
26
|
-
<div v-if="item.id" slot="content">P{{ item.id }}:{{ item.split }}</div>
|
|
27
|
-
<div v-if="item.id" style="cursor: pointer">
|
|
28
|
-
<div
|
|
29
|
-
class="box"
|
|
30
|
-
style="position: absolute; width:40px; left: 0; top: 5px"
|
|
31
|
-
>
|
|
32
|
-
<div class="ring-nums">P{{ item.id }}:{{ item.split }}</div>
|
|
33
|
-
</div>
|
|
34
|
-
</div>
|
|
35
|
-
</el-tooltip>
|
|
36
|
-
</div>
|
|
37
|
-
</div>
|
|
38
|
-
</div>
|
|
39
14
|
<!-- 环模式true -->
|
|
40
|
-
<div v-if="
|
|
15
|
+
<div v-if="this.contrloType === 'ring' || !this.contrloType">
|
|
41
16
|
<div class="ring-first" v-for="(list, index1) in patternInfo" :key="index1">
|
|
42
17
|
<draggable :move="move" @end="endDrag(index1)" :disabled="isMove" :list="list">
|
|
43
18
|
<div style="position: relative;" :style="{'height': '35px','float':'left','width':((item.split+(item.sum?item.sum:0)) / (max?max:item.cycle) * 100) + '%'}" v-for="(item,index2) in list" :key="index2" :class="item.mode === 7 ? 'direction' : isBorder ? 'hovercell' : ''">
|
|
@@ -159,7 +134,6 @@ export default {
|
|
|
159
134
|
newCycle: this.cycles,
|
|
160
135
|
patternIds: this.patternId,
|
|
161
136
|
newPatterns: [],
|
|
162
|
-
patternRcp: [],
|
|
163
137
|
newList: [],
|
|
164
138
|
isControl: true,
|
|
165
139
|
contrloCycle: 0,
|
|
@@ -196,9 +170,6 @@ export default {
|
|
|
196
170
|
controlPhase: {
|
|
197
171
|
type: Object
|
|
198
172
|
},
|
|
199
|
-
patternType: {
|
|
200
|
-
type: String
|
|
201
|
-
},
|
|
202
173
|
contrloType: {
|
|
203
174
|
type: String
|
|
204
175
|
},
|
|
@@ -371,9 +342,6 @@ export default {
|
|
|
371
342
|
cycles: {
|
|
372
343
|
handler: function (val, oldVal) {
|
|
373
344
|
this.newCycle = this.cycles
|
|
374
|
-
if (this.patternType === 'rcp') {
|
|
375
|
-
this.handleRcp(this.patternStatusList)
|
|
376
|
-
}
|
|
377
345
|
},
|
|
378
346
|
// 深度观察监听
|
|
379
347
|
deep: true
|
|
@@ -398,9 +366,6 @@ export default {
|
|
|
398
366
|
},
|
|
399
367
|
patternStatusList: {
|
|
400
368
|
handler: function (val, oldVal) {
|
|
401
|
-
if (this.patternType === 'rcp') {
|
|
402
|
-
this.handleRcp(this.patternStatusList)
|
|
403
|
-
}
|
|
404
369
|
this.handleBarrierHeight() // 计算屏障高度
|
|
405
370
|
if (this.patternStatusList && this.newCycle) {
|
|
406
371
|
// setTimeout(() => {
|
|
@@ -433,9 +398,6 @@ export default {
|
|
|
433
398
|
if (this.contrloType === 'stage') {
|
|
434
399
|
this.getStage()
|
|
435
400
|
}
|
|
436
|
-
if (this.patternType === 'rcp') {
|
|
437
|
-
this.handleRcp(this.patternStatusList)
|
|
438
|
-
}
|
|
439
401
|
},
|
|
440
402
|
methods: {
|
|
441
403
|
move (e) {
|
|
@@ -523,48 +485,6 @@ export default {
|
|
|
523
485
|
}
|
|
524
486
|
return ped
|
|
525
487
|
},
|
|
526
|
-
handleRcp (val) {
|
|
527
|
-
this.patternRcp = []
|
|
528
|
-
let valSplit = val.map(item => {
|
|
529
|
-
return item.map(val => {
|
|
530
|
-
return val.splitchain
|
|
531
|
-
})
|
|
532
|
-
})
|
|
533
|
-
let splitCycle = valSplit.length > 0 ? valSplit.map(item => {
|
|
534
|
-
return item.length > 0 ? item.reduce((a, b) => {
|
|
535
|
-
return a + b
|
|
536
|
-
}) : 0
|
|
537
|
-
}) : 0
|
|
538
|
-
let cycle = Math.max(...splitCycle)// 每个环的周期最大值
|
|
539
|
-
for (let rings of val) {
|
|
540
|
-
if (rings.length === 0) continue
|
|
541
|
-
let list = []
|
|
542
|
-
for (let ring of rings) {
|
|
543
|
-
if (ring.splitchain === 0) continue
|
|
544
|
-
let obj = {}
|
|
545
|
-
let split = ring.splitchain
|
|
546
|
-
obj.split = split
|
|
547
|
-
obj.cycle = cycle
|
|
548
|
-
obj.id = ring.phases
|
|
549
|
-
// if (ring.sum) {
|
|
550
|
-
// obj.sum = ring.sum
|
|
551
|
-
// obj.redWidth = ((currPhase.redclear + ring.sum) / (this.fixCycle ? this.fixCycle : this.max ? this.max : this.newCycle) * 100) + '%'
|
|
552
|
-
// } else {
|
|
553
|
-
// obj.redWidth = (currPhase.redclear / (this.fixCycle ? this.fixCycle : this.max ? this.max : this.newCycle) * 100) + '%'
|
|
554
|
-
// }
|
|
555
|
-
// obj.mode = ring.mode
|
|
556
|
-
obj.greenWidth = (split / (cycle > this.cycles ? cycle : this.cycles)) * 100 + '%'
|
|
557
|
-
// obj.flashgreen = (currPhase.flashgreen / (this.fixCycle ? this.fixCycle : this.max ? this.max : this.newCycle) * 100) + '%'
|
|
558
|
-
// obj.yellowWidth = (currPhase.yellow / (this.fixCycle ? this.fixCycle : this.max ? this.max : this.newCycle) * 100) + '%'
|
|
559
|
-
// 忽略相位不显示
|
|
560
|
-
// let mode = ring.mode
|
|
561
|
-
// if (mode !== 7) { // 忽略相位不显示
|
|
562
|
-
list.push(obj)
|
|
563
|
-
// }
|
|
564
|
-
}
|
|
565
|
-
this.patternRcp.push(list)
|
|
566
|
-
}
|
|
567
|
-
},
|
|
568
488
|
handleStageData (data) {
|
|
569
489
|
if (!data) return
|
|
570
490
|
let peddirections = this.getPed(data)
|
|
@@ -3,7 +3,6 @@
|
|
|
3
3
|
<BoardCard
|
|
4
4
|
:patternId="patternId"
|
|
5
5
|
:contrloType="contrloType"
|
|
6
|
-
:patternType="patternType"
|
|
7
6
|
:stagesChange="stagesChange"
|
|
8
7
|
:isShowTip="isShowTip"
|
|
9
8
|
:isBorder="isBorder"
|
|
@@ -553,9 +552,6 @@ export default {
|
|
|
553
552
|
patternStatusList: {
|
|
554
553
|
type: Array
|
|
555
554
|
},
|
|
556
|
-
patternType: {
|
|
557
|
-
type: String
|
|
558
|
-
},
|
|
559
555
|
patternId: {
|
|
560
556
|
type: Number
|
|
561
557
|
},
|
package/src/kisscomps/index.js
CHANGED
|
@@ -35,11 +35,12 @@ import IntersectionDirectionSelection from './components/IntersectionDirectionSe
|
|
|
35
35
|
import PhaseLegend from './components/PhaseLegend/index.js'
|
|
36
36
|
import OverviewComponent from './components/OverviewComponent/index.js'
|
|
37
37
|
import IntersectionMapDirSelect from './components/IntersectionMapDirSelect/index.js'
|
|
38
|
-
import { setToken, setHost, setIsCheckPermission, setUserRoles, setPermissions } from '../utils/auth.js'
|
|
38
|
+
import { setToken, setHost, setIsCheckPermission, setUserRoles, setPermissions, setLanguage, getLanguage } from '../utils/auth.js'
|
|
39
39
|
import componentsGlobalParam from '../store/modules/globalParam'
|
|
40
40
|
|
|
41
41
|
import en from '../i18n/language/en'
|
|
42
42
|
import zh from '../i18n/language/zh'
|
|
43
|
+
import ru from '../i18n/language/ru'
|
|
43
44
|
// 第三方插件
|
|
44
45
|
import VTooltip from 'v-tooltip'
|
|
45
46
|
|
|
@@ -84,10 +85,13 @@ const components = {
|
|
|
84
85
|
|
|
85
86
|
const language = {
|
|
86
87
|
en,
|
|
87
|
-
zh
|
|
88
|
+
zh,
|
|
89
|
+
ru
|
|
88
90
|
}
|
|
89
91
|
|
|
90
92
|
const func = {
|
|
93
|
+
getLanguage,
|
|
94
|
+
setLanguage,
|
|
91
95
|
setHost,
|
|
92
96
|
setToken,
|
|
93
97
|
setUserRoles,
|
|
@@ -166,7 +166,7 @@ export default {
|
|
|
166
166
|
// agentId: '0351-01',
|
|
167
167
|
reqUrl: 'http://192.168.13.103:10003/openatc',
|
|
168
168
|
Token135: 'eyJraWQiOiIxNzIzMDgzMDcxMzIxIiwidHlwIjoiSldUIiwiYWxnIjoiSFMyNTYifQ.eyJzdWIiOiJhZG1pbiIsImV4cCI6MTk4NTQ0MzIwMCwiaWF0IjoxNzIyNDM4MDAwfQ.i-RVHcxmtgvD9boQECpBCz7T1fJ0TAjzO5BWin3VdoY',
|
|
169
|
-
Token: '
|
|
169
|
+
Token: 'eyJraWQiOiIxNzU5OTk2MDExMTg5IiwidHlwIjoiSldUIiwiYWxnIjoiSFMyNTYifQ.eyJzdWIiOiJhZG1pbiIsImV4cCI6MTg5MDU3NjAwMCwiaWF0IjoxNzU5MjQ0NDAwfQ.N0igTWJwfGZYzZJX91V1pevh5Xi7-itNgobQcD7vv_k',
|
|
170
170
|
// reqUrl: 'http://192.168.13.113:10003/openatc',
|
|
171
171
|
// Token: 'eyJraWQiOiIxNjkxMzcxMTc5ODcxIiwidHlwIjoiSldUIiwiYWxnIjoiSFMyNTYifQ.eyJzdWIiOiJhZG1pbiIsImV4cCI6MTcxNDE0NzIwMCwiaWF0IjoxNjkwODE5MjAwfQ.AhUj9taw4_IpP77AmP5bvCE87dDQ4-ZdsEJzrlWXKF8',
|
|
172
172
|
// agentId: '30003-352',
|
|
@@ -14738,7 +14738,7 @@ export default {
|
|
|
14738
14738
|
// // _this.agentId = 'scats1'
|
|
14739
14739
|
// _this.agentids = ['gjnlahql', 'gjnlgjxl']
|
|
14740
14740
|
// }, 5 * 1000)
|
|
14741
|
-
this.setPropsToken(this.
|
|
14741
|
+
this.setPropsToken(this.Token)
|
|
14742
14742
|
// this.setPropsToken(this.Token)
|
|
14743
14743
|
window.onresize = () => {
|
|
14744
14744
|
return (() => {
|
|
@@ -62,7 +62,7 @@ export default {
|
|
|
62
62
|
sidewalkPhaseData: [{key: 'pedphase1653873194007699', phaseid: 1, id: 1, name: '东人行横道', isshow: false}],
|
|
63
63
|
lockPhaseBtnName: this.$t('openatccomponents.overview.comfirm'),
|
|
64
64
|
agentId: '32050101041121000001',
|
|
65
|
-
Token: '
|
|
65
|
+
Token: 'eyJraWQiOiIxNzU5OTk2MDExMTg5IiwidHlwIjoiSldUIiwiYWxnIjoiSFMyNTYifQ.eyJzdWIiOiJhZG1pbiIsImV4cCI6MTg5MDU3NjAwMCwiaWF0IjoxNzU5MjQ0NDAwfQ.N0igTWJwfGZYzZJX91V1pevh5Xi7-itNgobQcD7vv_k',
|
|
66
66
|
Token103: 'eyJraWQiOiIxNzAxODMyOTQ3MTUwIiwidHlwIjoiSldUIiwiYWxnIjoiSFMyNTYifQ.eyJzdWIiOiJxeXl0aCIsImV4cCI6MTc2OTc4ODgwMCwiaWF0IjoxNzAxMzYwMDAwfQ.RIQpNEkJibL-RYllirDeNLi8G9-t8PecM_m7KlZNQXg',
|
|
67
67
|
boxVisible: false,
|
|
68
68
|
dialogWidth: '80%',
|