openatc-components 0.2.9 → 0.2.10
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/OverLap/OverLap.vue +24 -3
- package/package/kisscomps/components/SchemeConfig/tentativeplancontrolmodal/index.vue +1 -1
- package/package/kissui.min.js +1 -1
- package/package.json +1 -1
- package/src/kisscomps/components/OverLap/OverLap.vue +24 -3
- package/src/kisscomps/components/SchemeConfig/tentativeplancontrolmodal/index.vue +1 -1
- package/static/styles/index.scss +1 -1
- package/static/styles/schemeconfig.scss +1 -4
|
@@ -47,7 +47,8 @@ export default {
|
|
|
47
47
|
},
|
|
48
48
|
data () {
|
|
49
49
|
return {
|
|
50
|
-
overlapDatas: []
|
|
50
|
+
overlapDatas: [],
|
|
51
|
+
max: ''
|
|
51
52
|
}
|
|
52
53
|
},
|
|
53
54
|
props: {
|
|
@@ -67,6 +68,10 @@ export default {
|
|
|
67
68
|
type: Boolean,
|
|
68
69
|
default: false
|
|
69
70
|
},
|
|
71
|
+
cycleChange: {
|
|
72
|
+
type: Boolean,
|
|
73
|
+
default: true
|
|
74
|
+
},
|
|
70
75
|
cycle: {
|
|
71
76
|
type: Number
|
|
72
77
|
},
|
|
@@ -82,6 +87,13 @@ export default {
|
|
|
82
87
|
// 深度观察监听
|
|
83
88
|
deep: true
|
|
84
89
|
},
|
|
90
|
+
cycleChange: {
|
|
91
|
+
handler: function (val, oldVal) {
|
|
92
|
+
this.doAdd(this.stageList, this.overlap)
|
|
93
|
+
},
|
|
94
|
+
// 深度观察监听
|
|
95
|
+
deep: true
|
|
96
|
+
},
|
|
85
97
|
stageList: {
|
|
86
98
|
handler: function (val, oldVal) {
|
|
87
99
|
this.doAdd(this.stageList, this.overlap)
|
|
@@ -140,6 +152,15 @@ export default {
|
|
|
140
152
|
if (findItems.length) findIndexs.push(...findItems.map(m => m.key))
|
|
141
153
|
})
|
|
142
154
|
findIndexs = Array.from(new Set(findIndexs))
|
|
155
|
+
if (this.cycleChange) {
|
|
156
|
+
const globalParamModel = this.$store.getters.globalParamModel
|
|
157
|
+
let pattern = globalParamModel.getParamsByType('patternList')
|
|
158
|
+
const allCycle = pattern.map(item => item.cycle)
|
|
159
|
+
let cycle = Math.max(...allCycle)
|
|
160
|
+
this.max = cycle
|
|
161
|
+
} else {
|
|
162
|
+
this.max = ''
|
|
163
|
+
}
|
|
143
164
|
return {
|
|
144
165
|
...item,
|
|
145
166
|
peddirection: this.getPedPhasePos(item.peddirection),
|
|
@@ -150,8 +171,8 @@ export default {
|
|
|
150
171
|
...sta,
|
|
151
172
|
direction: this.getRoad(item),
|
|
152
173
|
// peddirection: this.getPedPhasePos(item.peddirection),
|
|
153
|
-
greenWidth: find ? (sta.split / this.cycle * 100).toFixed(3) + '%' : '0%',
|
|
154
|
-
redWidth: !find ? (sta.split / this.cycle * 100).toFixed(3) + '%' : '0%'
|
|
174
|
+
greenWidth: find ? (sta.split / (this.max ? this.max : this.cycle) * 100).toFixed(3) + '%' : '0%',
|
|
175
|
+
redWidth: !find ? (sta.split / (this.max ? this.max : this.cycle) * 100).toFixed(3) + '%' : '0%'
|
|
155
176
|
}
|
|
156
177
|
})
|
|
157
178
|
}
|