openatc-components 0.3.111 → 0.3.112
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 +4 -11
- package/package/kisscomps/components/Channelization/Channelization.vue +1 -1
- package/package/kisscomps/components/ChannelizationFlowStatistic/ChannelizationFlowStatistic.vue +1 -1
- package/package/kisscomps/components/DrawChannelization/drawsvg/iconSvg/motorwayIconSvg.vue +145 -46
- package/package/kisscomps/components/DrawChannelization/drawsvg/index.draw.vue +4 -4
- package/package/kisscomps/components/DrawChannelization/drawsvg/index.vue +1 -1
- package/package/kisscomps/components/IntersectionMap/intersectionmap.vue +1 -1
- package/package/kisscomps/components/OptimizeKanban/index.js +2 -0
- package/package/kisscomps/components/OptimizeKanban/index.vue +369 -0
- package/package/kisscomps/components/OverviewComponent/index.vue +18 -12
- package/package/kisscomps/components/PatternOptimize/PatternOptimize.vue +2 -11
- package/package/kisscomps/components/PatternStatus/PatternStatus.vue +89 -84
- package/package/kisscomps/components/SchemeConfig/SchemeConfig.vue +5 -34
- package/package/kisscomps/components/SchemeConfig/lockingPhaselControlModal/index.vue +11 -9
- package/package/kisscomps/components/SchemeConfig/manualControlModalNew/controlModelGroup.vue +4 -6
- package/package/kisscomps/components/SchemeConfig/manualControlModalNew/icon.vue +0 -32
- package/package/kisscomps/components/SchemeConfig/manualControlModalNew/index.vue +12 -19
- package/package/kisscomps/components/overView/index.vue +25 -2
- package/package/kisscomps/components/patternList/patternList.vue +4 -11
- package/package/kissui.min.js +1 -1
- package/package.json +1 -1
- package/src/i18n/language/en.js +3 -6
- package/src/i18n/language/zh.js +3 -6
- package/src/kisscomps/components/BoardCard/BoardCard.vue +4 -11
- package/src/kisscomps/components/Channelization/Channelization.vue +1 -1
- package/src/kisscomps/components/ChannelizationFlowStatistic/ChannelizationFlowStatistic.vue +1 -1
- package/src/kisscomps/components/DrawChannelization/drawsvg/iconSvg/motorwayIconSvg.vue +145 -46
- package/src/kisscomps/components/DrawChannelization/drawsvg/index.draw.vue +4 -4
- package/src/kisscomps/components/DrawChannelization/drawsvg/index.vue +1 -1
- package/src/kisscomps/components/IntersectionMap/intersectionmap.vue +1 -1
- package/src/kisscomps/components/OverviewComponent/index.vue +18 -12
- package/src/kisscomps/components/PatternOptimize/PatternOptimize.vue +2 -11
- package/src/kisscomps/components/PatternStatus/PatternStatus.vue +89 -84
- package/src/kisscomps/components/SchemeConfig/SchemeConfig.vue +5 -34
- package/src/kisscomps/components/SchemeConfig/lockingPhaselControlModal/index.vue +11 -9
- package/src/kisscomps/components/SchemeConfig/manualControlModalNew/controlModelGroup.vue +4 -6
- package/src/kisscomps/components/SchemeConfig/manualControlModalNew/icon.vue +0 -32
- package/src/kisscomps/components/SchemeConfig/manualControlModalNew/index.vue +12 -19
- package/src/kisscomps/components/overView/index.vue +25 -2
- package/src/kisscomps/components/patternList/patternList.vue +4 -11
- package/src/node_modules/.package_versions.json +1 -0
- package/src/utils/ControlFormat.js +2 -2
- package/src/views/intersection.vue +6 -7
- package/src/views/intersection2.vue +4 -4
- package/src/views/overView.vue +5 -27
- package/static/apiconfig.json +0 -10
- package/static/styles/common.scss +3 -3
- package/static/styles/dark/theme/element-dark.scss +1 -1
- package/static/styles/intersection.scss +15 -5
- package/static/styles/light/theme/element-light.scss +1 -1
- package/static/styles/schemeconfig.scss +3 -6
- package/package/kisscomps/components/SchemeConfig/utils/thirdPartypermission.js +0 -95
- package/src/api/permission.js +0 -33
- package/src/kisscomps/components/SchemeConfig/utils/thirdPartypermission.js +0 -95
|
@@ -212,8 +212,8 @@ export default {
|
|
|
212
212
|
Detector: [], // 管理所有检测器
|
|
213
213
|
DetectorChart: [], // 管理所有检测器统计图
|
|
214
214
|
motorwayicon: '',
|
|
215
|
-
IconLengh:
|
|
216
|
-
IconWdith:
|
|
215
|
+
IconLengh: 60,
|
|
216
|
+
IconWdith: 134,
|
|
217
217
|
textareaW: 200,
|
|
218
218
|
textareaH: 100,
|
|
219
219
|
pedW: 206,
|
|
@@ -389,8 +389,8 @@ export default {
|
|
|
389
389
|
h: this.IconWdith,
|
|
390
390
|
angle: 0
|
|
391
391
|
}
|
|
392
|
-
this.IconLengh =
|
|
393
|
-
this.IconWdith =
|
|
392
|
+
this.IconLengh = 60
|
|
393
|
+
this.IconWdith = 134
|
|
394
394
|
let Motorwaysitem = {
|
|
395
395
|
index: this.index,
|
|
396
396
|
id: this.motorid,
|
|
@@ -92,7 +92,7 @@ export default {
|
|
|
92
92
|
// }
|
|
93
93
|
return
|
|
94
94
|
}
|
|
95
|
-
if (
|
|
95
|
+
if (JSON.stringify(data.data.data) === '{}') return
|
|
96
96
|
_this.pageindex = 2
|
|
97
97
|
_this.loadedChannelizatonData = JSON.parse(JSON.stringify(data.data.data))
|
|
98
98
|
})
|
|
@@ -48,7 +48,7 @@
|
|
|
48
48
|
</template>
|
|
49
49
|
|
|
50
50
|
<script>
|
|
51
|
-
import CrossDiagram from './crossDirection/crossDiagram
|
|
51
|
+
import CrossDiagram from './crossDirection/crossDiagram'
|
|
52
52
|
import { setToken } from '../../../utils/auth.js'
|
|
53
53
|
export default {
|
|
54
54
|
name: 'intersection-base-map',
|
|
@@ -11,9 +11,9 @@
|
|
|
11
11
|
**/
|
|
12
12
|
<template>
|
|
13
13
|
<div class="container-main">
|
|
14
|
-
<div
|
|
14
|
+
<div :style="{'transform': `scale(${shrink})`, 'transform-origin': 'left top', 'height': '100%'}">
|
|
15
15
|
<div class="tuxingjiemian" v-show="curHomePage === 'Graphical' || curHomePage === 'Channelization'" :class="{'minifont': curBodyWidth <= 650}">
|
|
16
|
-
<div :class="{'changeWidth': graphicMode
|
|
16
|
+
<div class="tuxing-left" :class="{'changeWidth': graphicMode}" ref="tuxingLeft">
|
|
17
17
|
<intersection-base-map
|
|
18
18
|
v-if="curHomePage === 'Graphical'"
|
|
19
19
|
ref="intersectionMap"
|
|
@@ -29,7 +29,7 @@
|
|
|
29
29
|
:AgentId="agentId"
|
|
30
30
|
:crossStatusData="crossStatusData"
|
|
31
31
|
:detectorStatusData="detectorStatusData" />
|
|
32
|
-
<div class="pattern-status" v-if="!graphicMode &&
|
|
32
|
+
<div class="pattern-status" v-if="!graphicMode && crossStatusData.control !== 1 && crossStatusData.control !== 2 && crossStatusData.control !== 3">
|
|
33
33
|
<div class="pattern-name cross-mess">{{$t('openatccomponents.overviewcomponent.patternstate')}}</div>
|
|
34
34
|
<div class="pattern-message">({{$t('openatccomponents.overviewcomponent.cycle')}}: {{controlData.cycle}} {{$t('openatccomponents.overviewcomponent.patternoffset')}}: {{controlData.patternoffset}} {{$t('openatccomponents.overviewcomponent.coordinationtime')}}: {{controlData.offset}})</div>
|
|
35
35
|
<span class="pattern-explain"><el-checkbox v-model="checked">{{$t('openatccomponents.overviewcomponent.overLap')}}</el-checkbox></span>
|
|
@@ -93,7 +93,7 @@
|
|
|
93
93
|
</div>
|
|
94
94
|
</div>
|
|
95
95
|
|
|
96
|
-
<div ref="tuxingRight" class="tuxing-right"
|
|
96
|
+
<div ref="tuxingRight" class="tuxing-right" >
|
|
97
97
|
<scheme-config
|
|
98
98
|
ref="rightpanel"
|
|
99
99
|
:statusData="crossStatusData"
|
|
@@ -103,6 +103,7 @@
|
|
|
103
103
|
:agentId="agentId"
|
|
104
104
|
:ip="ip"
|
|
105
105
|
:platform="platform"
|
|
106
|
+
:funcSort="FuncSort"
|
|
106
107
|
:roadDirection="roadDirection"
|
|
107
108
|
:isFromAtc="isfromatc" />
|
|
108
109
|
</div>
|
|
@@ -144,10 +145,6 @@ export default {
|
|
|
144
145
|
isfromatc: {
|
|
145
146
|
type: Boolean,
|
|
146
147
|
default: true
|
|
147
|
-
},
|
|
148
|
-
onlyShowIntersectionMap: {
|
|
149
|
-
type: Boolean,
|
|
150
|
-
default: false
|
|
151
148
|
}
|
|
152
149
|
},
|
|
153
150
|
data () {
|
|
@@ -171,8 +168,8 @@ export default {
|
|
|
171
168
|
detectorStatusTimer: null, // 检测器定时器
|
|
172
169
|
ParamsMode: new Map([[0, '自主控制'], [1, '本地手动'], [2, '平台控制'], [3, '配置软件控制'], [4, '遥控器控制'], [5, '黄闪器控制'], [6, '降级控制'], [7, '脚本控制'], [8, '算法控制']]),
|
|
173
170
|
ParamsModeEn: new Map([[0, 'Autonomous Control'], [1, 'Local Manual'], [2, 'Platform Control'], [3, 'Configuration Software Control'], [4, 'Remote Control'], [5, 'Yellow Flasher Control'], [6, 'Degradation Control'], [7, 'Script Control'], [8, 'Algorithm Control']]),
|
|
174
|
-
ParamsControl: new Map([[0, '多时段'], [1, '黄闪'], [2, '全红'], [3, '关灯'], [4, '步进'], [5, '定周期控制'], [6, '单点感应控制'], [7, '协调感应控制'], [8, '方案选择控制'], [9, '自适应控制'], [10, '无电缆控制'], [11, '有电缆控制'], [12, '行人过街控制'], [13, '方案恢复过渡'], [14, '相位驻留'], [15, '通道检测'], [16, '方向锁定'], [17, '韦伯斯特单点控制'], [18, '
|
|
175
|
-
ParamsControlEn: new Map([[0, 'Multi Period'], [1, 'Yellow Flash Control'], [2, 'Red Control'], [3, 'Dark Control'], [4, 'Step'], [5, 'Fixed_Cycle Control'], [6, 'Free Control'], [7, 'Coordinated Induction Control'], [8, 'Pattern Selection Control'], [9, 'Adaptive Control'], [10, 'Wireless Control'], [11, 'Cable Control'], [12, 'Pedestrian Crossing Control'], [13, 'Pattern recovery'], [14, 'Phase dwell'], [15, 'Channel Detection'], [16, 'Direction lock'], [17, 'Webster Single Point Coordination'], [18, '
|
|
171
|
+
ParamsControl: new Map([[0, '多时段'], [1, '黄闪'], [2, '全红'], [3, '关灯'], [4, '步进'], [5, '定周期控制'], [6, '单点感应控制'], [7, '协调感应控制'], [8, '方案选择控制'], [9, '自适应控制'], [10, '无电缆控制'], [11, '有电缆控制'], [12, '行人过街控制'], [13, '方案恢复过渡'], [14, '相位驻留'], [15, '通道检测'], [16, '方向锁定'], [17, '韦伯斯特单点控制'], [18, '预留18'], [19, '感应式行人过街'], [20, '方案干预'], [100, '方案干预'], [21, '预留21'], [22, '相位锁定'], [23, '相位放行控制'], [24, '紧急控制'], [99, '设备维护']]),
|
|
172
|
+
ParamsControlEn: new Map([[0, 'Multi Period'], [1, 'Yellow Flash Control'], [2, 'Red Control'], [3, 'Dark Control'], [4, 'Step'], [5, 'Fixed_Cycle Control'], [6, 'Free Control'], [7, 'Coordinated Induction Control'], [8, 'Pattern Selection Control'], [9, 'Adaptive Control'], [10, 'Wireless Control'], [11, 'Cable Control'], [12, 'Pedestrian Crossing Control'], [13, 'Pattern recovery'], [14, 'Phase dwell'], [15, 'Channel Detection'], [16, 'Direction lock'], [17, 'Webster Single Point Coordination'], [18, 'Reserving18'], [19, 'Inductive Pedestrian Crossing Control'], [20, 'Program Intervention'], [100, 'Program Intervention'], [21, 'Reserving21'], [22, 'Priority Control'], [23, 'Close Phase'], [24, 'Emergency Control'], [99, 'Device Mantenance']]),
|
|
176
173
|
phaseType: new Map([[1, '红'], [2, '黄'], [3, '绿'], [4, '绿闪']]), // phaseType表示红,黄,绿
|
|
177
174
|
phaseTypeEn: new Map([[1, 'Red'], [2, 'Yellow'], [3, 'Green'], [4, 'Greenclear']]), // phaseType表示红,黄,绿
|
|
178
175
|
ip: '--',
|
|
@@ -196,7 +193,8 @@ export default {
|
|
|
196
193
|
commonHeight: undefined, // 左右侧面板的高度值
|
|
197
194
|
graphicMode: false,
|
|
198
195
|
resetcomponent: true,
|
|
199
|
-
curHomePage: 'Graphical'
|
|
196
|
+
curHomePage: 'Graphical',
|
|
197
|
+
FuncSort: 'allFunc'
|
|
200
198
|
}
|
|
201
199
|
},
|
|
202
200
|
computed: {
|
|
@@ -339,7 +337,7 @@ export default {
|
|
|
339
337
|
return
|
|
340
338
|
}
|
|
341
339
|
// 路口已设置渠化,则总览默认显示渠化路口,未设置显示模版路口
|
|
342
|
-
if (_this.isfromatc === true && data.data.success === true &&
|
|
340
|
+
if (_this.isfromatc === true && data.data.success === true && JSON.stringify(data.data.data) !== '{}') {
|
|
343
341
|
_this.curHomePage = 'Channelization'
|
|
344
342
|
} else {
|
|
345
343
|
_this.curHomePage = 'Graphical'
|
|
@@ -783,6 +781,14 @@ export default {
|
|
|
783
781
|
this.agentName = res.data.data.name
|
|
784
782
|
}
|
|
785
783
|
this.platform = res.data.data.platform
|
|
784
|
+
let func = 'allFunc'
|
|
785
|
+
if (this.platform === 'OpenATC') {
|
|
786
|
+
func = 'allFunc'
|
|
787
|
+
}
|
|
788
|
+
if (this.platform === 'SCATS' || this.platform === 'HUATONG') {
|
|
789
|
+
func = 'basicFunc'
|
|
790
|
+
}
|
|
791
|
+
this.FuncSort = func
|
|
786
792
|
})
|
|
787
793
|
}
|
|
788
794
|
},
|
|
@@ -50,7 +50,7 @@
|
|
|
50
50
|
<el-tooltip class="item" effect="dark" placement="left">
|
|
51
51
|
<div slot="content">{{element.name}}</div>
|
|
52
52
|
<div class="common-phase-description">
|
|
53
|
-
<xdrdirselector Width="70px" Height="70px" Widths="
|
|
53
|
+
<xdrdirselector Width="70px" Height="70px" Widths="50px" Heights="50px" :Data="styles" :showlist="element.desc" :ISActiveMask="ISActiveMask" :MaskColor="MaskColor"></xdrdirselector>
|
|
54
54
|
</div>
|
|
55
55
|
</el-tooltip>
|
|
56
56
|
</el-col>
|
|
@@ -79,13 +79,9 @@ export default {
|
|
|
79
79
|
},
|
|
80
80
|
data () {
|
|
81
81
|
return {
|
|
82
|
-
showStyle: {
|
|
83
|
-
left: '2px',
|
|
84
|
-
top: '0px'
|
|
85
|
-
},
|
|
86
82
|
styles: {
|
|
87
83
|
left: '1px',
|
|
88
|
-
top: '
|
|
84
|
+
top: '0'
|
|
89
85
|
},
|
|
90
86
|
typeOptions: [{
|
|
91
87
|
value: 'flow-split-opt'
|
|
@@ -101,9 +97,6 @@ export default {
|
|
|
101
97
|
type: String,
|
|
102
98
|
default: 'Header'
|
|
103
99
|
},
|
|
104
|
-
id: {
|
|
105
|
-
type: Number
|
|
106
|
-
},
|
|
107
100
|
rings: {
|
|
108
101
|
type: Object
|
|
109
102
|
},
|
|
@@ -216,7 +209,6 @@ export default {
|
|
|
216
209
|
}
|
|
217
210
|
}
|
|
218
211
|
}
|
|
219
|
-
this.$emit('optimizesucess', this.id)
|
|
220
212
|
}
|
|
221
213
|
}).catch(error => {
|
|
222
214
|
console.log(error)
|
|
@@ -240,7 +232,6 @@ export default {
|
|
|
240
232
|
}
|
|
241
233
|
}
|
|
242
234
|
}
|
|
243
|
-
this.$emit('optimizesucess', this.id)
|
|
244
235
|
}
|
|
245
236
|
}).catch(error => {
|
|
246
237
|
console.log(error)
|
|
@@ -11,12 +11,36 @@
|
|
|
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>
|
|
14
39
|
<!-- 环模式true -->
|
|
15
|
-
<div v-if="this.contrloType === 'ring' || !this.contrloType">
|
|
40
|
+
<div v-if="(this.contrloType === 'ring' || !this.contrloType) && patternType !== 'rcp'">
|
|
16
41
|
<div class="ring-first" v-for="(list, index1) in patternInfo" :key="index1">
|
|
17
|
-
<
|
|
18
|
-
<div
|
|
19
|
-
<div class="first-1" :class="item.mode === 8 ? 'mask' : item.mode === 9 ? 'yellowClass' : ''" :style="{'width':Number(item.greenWidth.replace('%', ''))/Number((((item.split+(item.sum?item.sum:0)) / (max?max:item.cycle) * 100) + '%').replace('%', ''))*100+'%','height':'34px','background':'#7ccc66'}">
|
|
42
|
+
<div style="position: relative;" :style="{'height': '34px','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': ''">
|
|
43
|
+
<div class="first-1" :class="item.mode === 8 ? 'mask' : item.mode === 9 ? 'yellowClass' : ''" :style="{'width':Number(item.greenWidth.replace('%', ''))/Number((((item.split+(item.sum?item.sum:0)) / (max?max:item.cycle) * 100) + '%').replace('%', ''))*100+'%','height':'34px','background':'#7ccc66'}">
|
|
20
44
|
<el-tooltip placement="top-start" effect="light">
|
|
21
45
|
<div slot="content">{{$t('openatccomponents.phase.phase')}}{{item.id}}:{{item.split}}</div>
|
|
22
46
|
<div style="cursor:pointer;">
|
|
@@ -26,18 +50,7 @@
|
|
|
26
50
|
</div>
|
|
27
51
|
<div v-if="isShowTip" class="box" style="position: absolute; left:40px; width:40px; top: -1px;">
|
|
28
52
|
<div class="ring-nums">{{$t('openatccomponents.phase.phase')}}{{item.id}}</div>
|
|
29
|
-
<div
|
|
30
|
-
<el-input-number
|
|
31
|
-
v-if="!isMove"
|
|
32
|
-
class="ring-nums"
|
|
33
|
-
size="small"
|
|
34
|
-
:controls="false"
|
|
35
|
-
:min="0"
|
|
36
|
-
:step="1"
|
|
37
|
-
v-model.number="item.split"
|
|
38
|
-
@change="handleEdit(item)"
|
|
39
|
-
style="width: 24px"
|
|
40
|
-
></el-input-number>
|
|
53
|
+
<div class="ring-nums">{{item.split}}</div>
|
|
41
54
|
</div>
|
|
42
55
|
</div>
|
|
43
56
|
</el-tooltip>
|
|
@@ -53,8 +66,7 @@
|
|
|
53
66
|
<div class="first-1" :class="item.mode === 8 ? 'mask' : item.mode === 9 ? 'yellowClass' : ''" :style="{'width':Number(item.flashgreen.replace('%', ''))/Number((((item.split+(item.sum?item.sum:0)) / (max?max:item.cycle) * 100).toFixed(3) + '%').replace('%', ''))*100+'%','height':'34px','float':'left','background': 'linear-gradient(to right, #ffffff 50%, #7ccc66 0)','background-size': '4px 100%'}"></div>
|
|
54
67
|
<div class="first-1" :class="item.mode === 8 ? 'mask' : item.mode === 9 ? 'yellowClass' : ''" :style="{'width':Number(item.yellowWidth.replace('%', ''))/Number((((item.split+(item.sum?item.sum:0)) / (max?max:item.cycle) * 100) + '%').replace('%', ''))*100+'%','height':'34px','background':'#f9dc6a'}"></div>
|
|
55
68
|
<div class="first-1" :class="item.mode === 8 ? 'mask' : item.mode === 9 ? 'yellowClass' : ''" :style="{'width':Number(item.redWidth.replace('%', ''))/Number((((item.split+(item.sum?item.sum:0)) / (max?max:item.cycle) * 100).toFixed(3) + '%').replace('%', ''))*100+'%','height':'34px','background':'#f27979'}"></div>
|
|
56
|
-
|
|
57
|
-
</draggable>
|
|
69
|
+
</div>
|
|
58
70
|
</div>
|
|
59
71
|
<div v-if="showBarrier">
|
|
60
72
|
<div v-for="(item, index) in barrierList" :key="index + '1'">
|
|
@@ -113,7 +125,6 @@
|
|
|
113
125
|
<script>
|
|
114
126
|
// import patternwalksvg from '../PatternWalkSvg/PatternWalkSvg'
|
|
115
127
|
import xdrdirselector from '../XRDDirSelector/XRDDirSelector'
|
|
116
|
-
import draggable from 'vuedraggable'
|
|
117
128
|
// import PatternWalkSvg from '../IntersectionMap/crossDirection/baseImg/PatternWalkSvg'
|
|
118
129
|
import PhaseDataModel from '../IntersectionMap/crossDirection/utils.js'
|
|
119
130
|
import CrossDiagramMgr from '../../../EdgeMgr/controller/crossDiagramMgr.js'
|
|
@@ -121,7 +132,6 @@ export default {
|
|
|
121
132
|
name: 'pattern-list',
|
|
122
133
|
components: {
|
|
123
134
|
// patternwalksvg,
|
|
124
|
-
draggable,
|
|
125
135
|
xdrdirselector
|
|
126
136
|
},
|
|
127
137
|
data () {
|
|
@@ -129,10 +139,10 @@ export default {
|
|
|
129
139
|
barrierHeight: '',
|
|
130
140
|
stageCycle: '',
|
|
131
141
|
barrierList: [],
|
|
132
|
-
barrierArr: [],
|
|
133
142
|
newCycle: this.cycles,
|
|
134
143
|
patternIds: this.patternId,
|
|
135
144
|
newPatterns: [],
|
|
145
|
+
patternRcp: [],
|
|
136
146
|
newList: [],
|
|
137
147
|
isControl: true,
|
|
138
148
|
contrloCycle: 0,
|
|
@@ -158,13 +168,12 @@ export default {
|
|
|
158
168
|
stagesChange: {
|
|
159
169
|
type: Array
|
|
160
170
|
},
|
|
161
|
-
isMove: {
|
|
162
|
-
type: Boolean,
|
|
163
|
-
default: true
|
|
164
|
-
},
|
|
165
171
|
controlPhase: {
|
|
166
172
|
type: Object
|
|
167
173
|
},
|
|
174
|
+
patternType: {
|
|
175
|
+
type: String
|
|
176
|
+
},
|
|
168
177
|
contrloType: {
|
|
169
178
|
type: String
|
|
170
179
|
},
|
|
@@ -337,6 +346,9 @@ export default {
|
|
|
337
346
|
cycles: {
|
|
338
347
|
handler: function (val, oldVal) {
|
|
339
348
|
this.newCycle = this.cycles
|
|
349
|
+
if (this.patternType === 'rcp') {
|
|
350
|
+
this.handleRcp(this.patternStatusList)
|
|
351
|
+
}
|
|
340
352
|
},
|
|
341
353
|
// 深度观察监听
|
|
342
354
|
deep: true
|
|
@@ -361,13 +373,16 @@ export default {
|
|
|
361
373
|
},
|
|
362
374
|
patternStatusList: {
|
|
363
375
|
handler: function (val, oldVal) {
|
|
376
|
+
if (this.patternType === 'rcp') {
|
|
377
|
+
this.handleRcp(this.patternStatusList)
|
|
378
|
+
}
|
|
364
379
|
this.handleBarrierHeight() // 计算屏障高度
|
|
365
380
|
if (this.patternStatusList && this.newCycle) {
|
|
366
|
-
|
|
367
|
-
|
|
381
|
+
setTimeout(() => {
|
|
382
|
+
this.handleCurrentChange(this.patternStatusList)
|
|
383
|
+
this.handleBarrierHeight()
|
|
384
|
+
}, 10)
|
|
368
385
|
this.handleBarrierHeight()
|
|
369
|
-
// }, 10)
|
|
370
|
-
// this.handleBarrierHeight()
|
|
371
386
|
}
|
|
372
387
|
},
|
|
373
388
|
// 深度观察监听
|
|
@@ -393,62 +408,11 @@ export default {
|
|
|
393
408
|
if (this.contrloType === 'stage') {
|
|
394
409
|
this.getStage()
|
|
395
410
|
}
|
|
411
|
+
if (this.patternType === 'rcp') {
|
|
412
|
+
this.handleRcp(this.patternStatusList)
|
|
413
|
+
}
|
|
396
414
|
},
|
|
397
415
|
methods: {
|
|
398
|
-
move (e) {
|
|
399
|
-
// 这里的e表示即将停靠的元素。
|
|
400
|
-
let result = this.barrierArr.filter(item => item.includes(e.relatedContext.element.id))[0]
|
|
401
|
-
if (!result.includes(e.draggedContext.element.id)) {
|
|
402
|
-
return false
|
|
403
|
-
}
|
|
404
|
-
},
|
|
405
|
-
endDrag (index) {
|
|
406
|
-
// 拖动后对原数据排序
|
|
407
|
-
const idIndexMap = {}
|
|
408
|
-
this.patternInfo.forEach((subArray, subArrayIndex) => {
|
|
409
|
-
subArray.forEach((item, index) => {
|
|
410
|
-
idIndexMap[item.id] = { subArrayIndex, index }
|
|
411
|
-
})
|
|
412
|
-
})
|
|
413
|
-
this.patternStatusList.forEach((subArray, subArrayIndex) => {
|
|
414
|
-
if (subArray.length > 0) {
|
|
415
|
-
subArray.sort((aItem, bItem) => {
|
|
416
|
-
const aIndex = idIndexMap[aItem.id] ? idIndexMap[aItem.id].index : Infinity
|
|
417
|
-
const bIndex = idIndexMap[bItem.id] ? idIndexMap[bItem.id].index : Infinity
|
|
418
|
-
return aIndex - bIndex
|
|
419
|
-
})
|
|
420
|
-
}
|
|
421
|
-
})
|
|
422
|
-
},
|
|
423
|
-
handleEdit (val) {
|
|
424
|
-
this.patternStatusList.map(d => {
|
|
425
|
-
d.map(r => {
|
|
426
|
-
if (r.id === val.id) {
|
|
427
|
-
r.value = val.split
|
|
428
|
-
}
|
|
429
|
-
})
|
|
430
|
-
})
|
|
431
|
-
// this.handleCurrentChange(this.patternStatusList)
|
|
432
|
-
this.$emit('handleSplitMove', this.patternId)
|
|
433
|
-
},
|
|
434
|
-
getMaxCycle (pattern) {
|
|
435
|
-
// let rings = pattern.rings
|
|
436
|
-
let maxCycle = 0
|
|
437
|
-
for (let ring of pattern) {
|
|
438
|
-
if (ring.length === 0) continue
|
|
439
|
-
let cycle = 0
|
|
440
|
-
for (let r of ring) {
|
|
441
|
-
if (r.mode === 7) { // 忽略相位不计周期
|
|
442
|
-
continue
|
|
443
|
-
}
|
|
444
|
-
cycle = cycle + r.value
|
|
445
|
-
}
|
|
446
|
-
if (cycle > maxCycle) {
|
|
447
|
-
maxCycle = cycle
|
|
448
|
-
}
|
|
449
|
-
}
|
|
450
|
-
return maxCycle
|
|
451
|
-
},
|
|
452
416
|
getPed (data) {
|
|
453
417
|
let ped = []
|
|
454
418
|
for (let stg of data) {
|
|
@@ -475,6 +439,48 @@ export default {
|
|
|
475
439
|
}
|
|
476
440
|
return ped
|
|
477
441
|
},
|
|
442
|
+
handleRcp (val) {
|
|
443
|
+
this.patternRcp = []
|
|
444
|
+
let valSplit = val.map(item => {
|
|
445
|
+
return item.map(val => {
|
|
446
|
+
return val.splitchain
|
|
447
|
+
})
|
|
448
|
+
})
|
|
449
|
+
let splitCycle = valSplit.length > 0 ? valSplit.map(item => {
|
|
450
|
+
return item.length > 0 ? item.reduce((a, b) => {
|
|
451
|
+
return a + b
|
|
452
|
+
}) : 0
|
|
453
|
+
}) : 0
|
|
454
|
+
let cycle = Math.max(...splitCycle)// 每个环的周期最大值
|
|
455
|
+
for (let rings of val) {
|
|
456
|
+
if (rings.length === 0) continue
|
|
457
|
+
let list = []
|
|
458
|
+
for (let ring of rings) {
|
|
459
|
+
if (ring.splitchain === 0) continue
|
|
460
|
+
let obj = {}
|
|
461
|
+
let split = ring.splitchain
|
|
462
|
+
obj.split = split
|
|
463
|
+
obj.cycle = cycle
|
|
464
|
+
obj.id = ring.phases
|
|
465
|
+
// if (ring.sum) {
|
|
466
|
+
// obj.sum = ring.sum
|
|
467
|
+
// obj.redWidth = ((currPhase.redclear + ring.sum) / (this.fixCycle ? this.fixCycle : this.max ? this.max : this.newCycle) * 100) + '%'
|
|
468
|
+
// } else {
|
|
469
|
+
// obj.redWidth = (currPhase.redclear / (this.fixCycle ? this.fixCycle : this.max ? this.max : this.newCycle) * 100) + '%'
|
|
470
|
+
// }
|
|
471
|
+
// obj.mode = ring.mode
|
|
472
|
+
obj.greenWidth = (split / (cycle > this.cycles ? cycle : this.cycles)) * 100 + '%'
|
|
473
|
+
// obj.flashgreen = (currPhase.flashgreen / (this.fixCycle ? this.fixCycle : this.max ? this.max : this.newCycle) * 100) + '%'
|
|
474
|
+
// obj.yellowWidth = (currPhase.yellow / (this.fixCycle ? this.fixCycle : this.max ? this.max : this.newCycle) * 100) + '%'
|
|
475
|
+
// 忽略相位不显示
|
|
476
|
+
// let mode = ring.mode
|
|
477
|
+
// if (mode !== 7) { // 忽略相位不显示
|
|
478
|
+
list.push(obj)
|
|
479
|
+
// }
|
|
480
|
+
}
|
|
481
|
+
this.patternRcp.push(list)
|
|
482
|
+
}
|
|
483
|
+
},
|
|
478
484
|
handleStageData (data) {
|
|
479
485
|
if (!data) return
|
|
480
486
|
let peddirections = this.getPed(data)
|
|
@@ -1253,7 +1259,6 @@ export default {
|
|
|
1253
1259
|
}
|
|
1254
1260
|
}
|
|
1255
1261
|
let resArr = ringArr.map(item => item.data)
|
|
1256
|
-
this.barrierArr = resArr
|
|
1257
1262
|
let ringTeam = this.step1(this.phaseList, resArr)
|
|
1258
1263
|
let ringTeams = ringTeam.filter(item => item.length !== 0)
|
|
1259
1264
|
if (this.patternList) {
|
|
@@ -40,8 +40,6 @@
|
|
|
40
40
|
:patternSelect="patternSelect"
|
|
41
41
|
:allPatternList="allPatternList"
|
|
42
42
|
:funcSort="funcSort"
|
|
43
|
-
:thirdPartyControlMenu="thirdPartyControlMenu"
|
|
44
|
-
:thirdPartyControl="thirdPartyControl"
|
|
45
43
|
:isShowBack="isShowBack"
|
|
46
44
|
:isShowRecovery="isShowRecovery"
|
|
47
45
|
:isShowImplement="isShowImplement"
|
|
@@ -106,8 +104,6 @@
|
|
|
106
104
|
:patternSelect="patternSelect"
|
|
107
105
|
:allPatternList="allPatternList"
|
|
108
106
|
:funcSort="funcSort"
|
|
109
|
-
:thirdPartyControlMenu="thirdPartyControlMenu"
|
|
110
|
-
:thirdPartyControl="thirdPartyControl"
|
|
111
107
|
:isShowBack="isShowBack"
|
|
112
108
|
:isShowRecovery="isShowRecovery"
|
|
113
109
|
:isShowImplement="isShowImplement"
|
|
@@ -142,8 +138,6 @@ import CrossDiagramMgr from '../../../EdgeMgr/controller/crossDiagramMgr.js'
|
|
|
142
138
|
import { setToken, setHost, getTheme } from '../../../utils/auth.js'
|
|
143
139
|
import RingDataModel from '../../../utils/RingDataModel.js'
|
|
144
140
|
import { getIntersectionInfo } from '../../../api/template'
|
|
145
|
-
import { GetRoleByName } from '../../../api/permission.js'
|
|
146
|
-
import { getPermissionMenu, getPermissionControl } from './utils/thirdPartypermission.js'
|
|
147
141
|
|
|
148
142
|
export default {
|
|
149
143
|
name: 'scheme-config',
|
|
@@ -206,6 +200,10 @@ export default {
|
|
|
206
200
|
type: String,
|
|
207
201
|
default: ''
|
|
208
202
|
},
|
|
203
|
+
funcSort: {
|
|
204
|
+
type: String,
|
|
205
|
+
default: 'allFunc'
|
|
206
|
+
},
|
|
209
207
|
roadDirection: {
|
|
210
208
|
type: String,
|
|
211
209
|
default: 'right'
|
|
@@ -421,13 +419,6 @@ export default {
|
|
|
421
419
|
permission: 'configer:manual:base',
|
|
422
420
|
iconName: this.$t('openatccomponents.overview.modelList19'),
|
|
423
421
|
bgcolor: getTheme() === 'light' ? '#edf6ff' : '#243d59'
|
|
424
|
-
}, {
|
|
425
|
-
type: '感应式自适应',
|
|
426
|
-
id: 18,
|
|
427
|
-
iconClass: 'ganyingshizishiying',
|
|
428
|
-
permission: 'configer:manual:base',
|
|
429
|
-
iconName: this.$t('openatccomponents.overview.modelList18'),
|
|
430
|
-
bgcolor: getTheme() === 'light' ? '#edf6ff' : '#243d59'
|
|
431
422
|
}
|
|
432
423
|
],
|
|
433
424
|
othersControlList: [
|
|
@@ -474,10 +465,7 @@ export default {
|
|
|
474
465
|
patternSelect: [], // 所有方案id
|
|
475
466
|
specialPage: '', // 哪一个特殊控制页面
|
|
476
467
|
nextcycleefficcontrol: [5, 6, 9, 10, 12, 19], // 下周期生效的控制方式
|
|
477
|
-
resetcomponent: false
|
|
478
|
-
funcSort: 'allFunc',
|
|
479
|
-
thirdPartyControlMenu: [],
|
|
480
|
-
thirdPartyControl: []
|
|
468
|
+
resetcomponent: false
|
|
481
469
|
}
|
|
482
470
|
},
|
|
483
471
|
watch: {
|
|
@@ -625,25 +613,8 @@ export default {
|
|
|
625
613
|
changeStatus () {
|
|
626
614
|
this.toPage = 1
|
|
627
615
|
this.isOperation = true
|
|
628
|
-
if (this.platform !== undefined && this.platform !== 'OpenATC') {
|
|
629
|
-
this.queryThirdParty()
|
|
630
|
-
}
|
|
631
616
|
this.$refs.ManualControlModalNew.init()
|
|
632
617
|
},
|
|
633
|
-
queryThirdParty () {
|
|
634
|
-
this.funcSort = 'allFunc'
|
|
635
|
-
GetRoleByName(`thirdparty--${this.platform}`).then(res => {
|
|
636
|
-
if (!res.data.success) {
|
|
637
|
-
let msg = getMessageByCode(res.data.code, this.$i18n.locale)
|
|
638
|
-
this.$message.error(msg)
|
|
639
|
-
return
|
|
640
|
-
}
|
|
641
|
-
this.funcSort = 'thirdPartyFunc'
|
|
642
|
-
this.thirdPartyControl = getPermissionControl(res.data.data)
|
|
643
|
-
this.thirdPartyControlMenu = getPermissionMenu(this.thirdPartyControl)
|
|
644
|
-
this.$refs.ManualControlModalNew.activeName = this.thirdPartyControlMenu[0]
|
|
645
|
-
})
|
|
646
|
-
},
|
|
647
618
|
handleGetData (data) {
|
|
648
619
|
let that = this
|
|
649
620
|
if (data.name === '') {
|
|
@@ -20,10 +20,10 @@
|
|
|
20
20
|
:model="manualInfo"
|
|
21
21
|
label-width="90px">
|
|
22
22
|
<el-form-item
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
23
|
+
:label="$t('openatccomponents.overview.greenclear')"
|
|
24
|
+
prop="intersection">
|
|
25
|
+
<el-input-number :min="0" :max="65535" :precision="0" :step="1" :controls="false" v-model.number="manualInfo.tempGreenflash" size="small"></el-input-number>
|
|
26
|
+
</el-form-item>
|
|
27
27
|
|
|
28
28
|
<el-form-item
|
|
29
29
|
:label="$t('openatccomponents.overview.yellowflash')"
|
|
@@ -44,11 +44,13 @@
|
|
|
44
44
|
label-position="left"
|
|
45
45
|
:model="manualInfo"
|
|
46
46
|
label-width="90px">
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
47
|
+
|
|
48
|
+
<el-form-item
|
|
49
|
+
:label="$t('openatccomponents.overview.duration')"
|
|
50
|
+
prop="count">
|
|
51
|
+
<el-input-number :min="0" :max="65535" :precision="0" :step="1" :controls="false" v-model.number="manualInfo.tempDuration" size="small"></el-input-number>
|
|
52
|
+
</el-form-item>
|
|
53
|
+
|
|
52
54
|
<el-form-item
|
|
53
55
|
:label="$t('openatccomponents.overview.allred')"
|
|
54
56
|
prop="intersection">
|
|
@@ -18,7 +18,7 @@
|
|
|
18
18
|
<div class="single-model-new"
|
|
19
19
|
:style="{'backgroundColor': item.bgcolor}"
|
|
20
20
|
@click="selectModel(item)"
|
|
21
|
-
v-if="isHasPermission(item.permission)
|
|
21
|
+
v-if="isHasPermission(item.permission)">
|
|
22
22
|
<div class="closephase-icon">
|
|
23
23
|
<OthersIconSvg :type="item.type" />
|
|
24
24
|
</div>
|
|
@@ -31,7 +31,7 @@
|
|
|
31
31
|
:style="{'backgroundColor': item.bgcolor}"
|
|
32
32
|
@click="selectModel(item)"
|
|
33
33
|
:class="preselecttype == item.type? 'single-model-select' : ''"
|
|
34
|
-
v-if="isHasPermission(item.permission) && (funcSort === 'allFunc' || (funcSort === '
|
|
34
|
+
v-if="isHasPermission(item.permission) && (funcSort === 'allFunc' || (funcSort === 'basicFunc'&& basicFuncControlId.indexOf(item.id) !== -1))">
|
|
35
35
|
<!-- <svg-icon :icon-class="item.iconClass" className="model-icon"></svg-icon> -->
|
|
36
36
|
<div class="model-icon">
|
|
37
37
|
<IconSvg :type="item.type" />
|
|
@@ -70,16 +70,14 @@ export default {
|
|
|
70
70
|
othersControl: {
|
|
71
71
|
type: Boolean,
|
|
72
72
|
default: false
|
|
73
|
-
},
|
|
74
|
-
thirdPartyControl: {
|
|
75
|
-
type: Array
|
|
76
73
|
}
|
|
77
74
|
},
|
|
78
75
|
data () {
|
|
79
76
|
return {
|
|
80
77
|
preselecttype: '',
|
|
81
78
|
controllist: [],
|
|
82
|
-
specialControl: [23, 24,
|
|
79
|
+
specialControl: [23, 22, 100, 24, 25],
|
|
80
|
+
basicFuncControlId: [0, 1, 4, 5] // 基础功能包含的控制方式: 自主控制(手动下)、黄闪、步进、定周期
|
|
83
81
|
}
|
|
84
82
|
},
|
|
85
83
|
computed: {
|