openatc-components 0.3.75 → 0.3.77
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 +11 -0
- package/package/kisscomps/components/ChannelRealtimeIntersection/ChannelRealtimeIntersection.vue +1 -1
- package/package/kisscomps/components/DrawChannelization/drawsvg/index.draw.vue +1 -1
- package/package/kisscomps/components/IntersectionDirectionSelection/IntersectionDirectionSelection.vue +1 -1
- package/package/kisscomps/components/IntersectionWithInterface/IntersectionWithInterface.vue +1 -1
- package/package/kisscomps/components/PatternOptimize/PatternOptimize.vue +11 -2
- package/package/kisscomps/components/PatternStatus/PatternStatus.vue +83 -8
- package/package/kisscomps/components/overView/index.vue +2 -2
- package/package/kisscomps/components/patternConfig/planContent.vue +4 -4
- package/package/kisscomps/components/patternConfig/planMenu.vue +7 -7
- package/package/kisscomps/components/patternList/patternList.vue +11 -0
- package/package/kissui.min.js +1 -1
- package/package.json +1 -1
- package/src/i18n/language/en.js +14 -9
- package/src/i18n/language/zh.js +14 -9
- package/src/kisscomps/components/BoardCard/BoardCard.vue +11 -0
- package/src/kisscomps/components/ChannelRealtimeIntersection/ChannelRealtimeIntersection.vue +1 -1
- package/src/kisscomps/components/DrawChannelization/drawsvg/index.draw.vue +1 -1
- package/src/kisscomps/components/IntersectionDirectionSelection/IntersectionDirectionSelection.vue +1 -1
- package/src/kisscomps/components/IntersectionWithInterface/IntersectionWithInterface.vue +1 -1
- package/src/kisscomps/components/PatternOptimize/PatternOptimize.vue +11 -2
- package/src/kisscomps/components/PatternStatus/PatternStatus.vue +83 -8
- package/src/kisscomps/components/overView/index.vue +2 -2
- package/src/kisscomps/components/patternConfig/planContent.vue +4 -4
- package/src/kisscomps/components/patternConfig/planMenu.vue +7 -7
- package/src/kisscomps/components/patternList/patternList.vue +11 -0
package/package.json
CHANGED
package/src/i18n/language/en.js
CHANGED
|
@@ -100,7 +100,8 @@ const en = {
|
|
|
100
100
|
'options8': 'Detector',
|
|
101
101
|
'options9': 'PedestrianDetector',
|
|
102
102
|
'graphics': 'Graphics interface',
|
|
103
|
-
'text': 'Text interface'
|
|
103
|
+
'text': 'Text interface',
|
|
104
|
+
'routeOptimize': 'Route Optimize'
|
|
104
105
|
},
|
|
105
106
|
'overview': {
|
|
106
107
|
'crossinfo': 'Cross Information',
|
|
@@ -110,9 +111,11 @@ const en = {
|
|
|
110
111
|
'signalID': 'Intersection ID',
|
|
111
112
|
'flow': 'Average lane flow (h)low',
|
|
112
113
|
'saturationflow': 'Planned lane saturation Flow(h)',
|
|
113
|
-
'typeflow-split-opt': 'Flow Split Op',
|
|
114
|
+
// 'typeflow-split-opt': 'Flow Split Op',
|
|
115
|
+
'typeflow-split-opt': 'Minimum delay',
|
|
116
|
+
'typecycle-opt': 'Optimal balance',
|
|
114
117
|
'maxFlow': 'The average lane flow is too large. Is it further optimized?',
|
|
115
|
-
'typecycle-opt': 'Cycle Opt',
|
|
118
|
+
// 'typecycle-opt': 'Cycle Opt',
|
|
116
119
|
'signalIP': 'Signal IP',
|
|
117
120
|
'stagecountdown': 'Stage Countdown',
|
|
118
121
|
'stageduration': 'Stage Duration',
|
|
@@ -902,7 +905,8 @@ const en = {
|
|
|
902
905
|
'ignore': 'Ignore',
|
|
903
906
|
'confirm': 'Confirm',
|
|
904
907
|
'save': 'Save',
|
|
905
|
-
'reset': 'Reset'
|
|
908
|
+
'reset': 'Reset',
|
|
909
|
+
'download': 'Download'
|
|
906
910
|
},
|
|
907
911
|
'common': {
|
|
908
912
|
'confirm': 'Confirm',
|
|
@@ -915,6 +919,7 @@ const en = {
|
|
|
915
919
|
'clone': 'Clone',
|
|
916
920
|
'deleteall': 'DeleteAll',
|
|
917
921
|
'update': 'Update',
|
|
922
|
+
'edit': 'Edit',
|
|
918
923
|
'search': 'Search',
|
|
919
924
|
'alarm': 'Alarm',
|
|
920
925
|
'none': 'none',
|
|
@@ -927,16 +932,16 @@ const en = {
|
|
|
927
932
|
'description': 'Description',
|
|
928
933
|
'operations': 'Operations',
|
|
929
934
|
'addfailed': 'Add Success!',
|
|
930
|
-
'
|
|
935
|
+
'addsuccess': 'Add Failed!',
|
|
931
936
|
'addcancel': 'Add Canceled!',
|
|
932
937
|
'deletefailed': 'Delete Failed!',
|
|
933
|
-
'
|
|
938
|
+
'deletesuccess': 'Delete Success!',
|
|
934
939
|
'deletecancel': 'Delete Canceled!',
|
|
935
940
|
'updatefailed': 'Update Failed!',
|
|
936
|
-
'
|
|
941
|
+
'updatesuccess': 'Update Success!',
|
|
937
942
|
'updatecancel': 'Update Canceled!',
|
|
938
943
|
'relatefailed': 'Relate Failed!',
|
|
939
|
-
'
|
|
944
|
+
'relatesuccess': 'Relate Success!',
|
|
940
945
|
'relatecancel': 'Relate Canceled!',
|
|
941
946
|
'upload': 'Upload',
|
|
942
947
|
'select': 'Select',
|
|
@@ -955,7 +960,7 @@ const en = {
|
|
|
955
960
|
'tipsmodaltitle': 'Tips',
|
|
956
961
|
'deviceoffline': 'Device not online!',
|
|
957
962
|
'operationsuccess': 'Operation Success !',
|
|
958
|
-
'
|
|
963
|
+
'savesuccess': 'Save Success!'
|
|
959
964
|
},
|
|
960
965
|
'login': {
|
|
961
966
|
'title': 'Openatc-Configer',
|
package/src/i18n/language/zh.js
CHANGED
|
@@ -100,15 +100,18 @@ const zh = {
|
|
|
100
100
|
'options8': '检测器',
|
|
101
101
|
'options9': '行人检测器',
|
|
102
102
|
'graphics': '图形界面',
|
|
103
|
-
'text': '文字界面'
|
|
103
|
+
'text': '文字界面',
|
|
104
|
+
'routeOptimize': '干线协调'
|
|
104
105
|
},
|
|
105
106
|
'overview': {
|
|
106
107
|
'crossinfo': '路口信息',
|
|
107
108
|
'flow': '车道平均流量(h)',
|
|
108
109
|
'saturationflow': '车道规划饱和流量(h)',
|
|
109
|
-
'typeflow-split-opt': '饱和绿信比优化',
|
|
110
|
+
// 'typeflow-split-opt': '饱和绿信比优化',
|
|
110
111
|
'maxFlow': '车道平均流量过大,是否继续优化?',
|
|
111
|
-
'typecycle-opt': '周期优化',
|
|
112
|
+
// 'typecycle-opt': '周期优化',
|
|
113
|
+
'typeflow-split-opt': '最小延误',
|
|
114
|
+
'typecycle-opt': '均衡度最优',
|
|
112
115
|
'crossname': '路口名称',
|
|
113
116
|
'divicestate': '设备状态',
|
|
114
117
|
'protocoltype': '协议类型',
|
|
@@ -901,7 +904,8 @@ const zh = {
|
|
|
901
904
|
'ignore': '忽略',
|
|
902
905
|
'confirm': '确认',
|
|
903
906
|
'save': '保存',
|
|
904
|
-
'reset': '重置'
|
|
907
|
+
'reset': '重置',
|
|
908
|
+
'download': '下载'
|
|
905
909
|
},
|
|
906
910
|
'common': {
|
|
907
911
|
'confirm': '确认',
|
|
@@ -914,6 +918,7 @@ const zh = {
|
|
|
914
918
|
'clone': '克隆',
|
|
915
919
|
'deleteall': '全部删除',
|
|
916
920
|
'update': '修改',
|
|
921
|
+
'edit': '编辑',
|
|
917
922
|
'enter': '请输入',
|
|
918
923
|
'search': '搜索',
|
|
919
924
|
'alarm': '警告',
|
|
@@ -926,16 +931,16 @@ const zh = {
|
|
|
926
931
|
'description': '描 述',
|
|
927
932
|
'operations': '操 作',
|
|
928
933
|
'addfailed': '添加失败!',
|
|
929
|
-
'
|
|
934
|
+
'addsuccess': '添加成功!',
|
|
930
935
|
'addcancel': '添加取消!',
|
|
931
936
|
'deletefailed': '删除失败!',
|
|
932
|
-
'
|
|
937
|
+
'deletesuccess': '删除成功!',
|
|
933
938
|
'deletecancel': '删除取消!',
|
|
934
939
|
'updatefailed': '更新失败!',
|
|
935
|
-
'
|
|
940
|
+
'updatesuccess': '更新成功!',
|
|
936
941
|
'updatecancel': '更新取消!',
|
|
937
942
|
'relatefailed': '关联失败!',
|
|
938
|
-
'
|
|
943
|
+
'relatesuccess': '关联成功!',
|
|
939
944
|
'relatecancel': '关联取消!',
|
|
940
945
|
'upload': '上传',
|
|
941
946
|
'select': '请选择',
|
|
@@ -954,7 +959,7 @@ const zh = {
|
|
|
954
959
|
'tipsmodaltitle': '提示',
|
|
955
960
|
'deviceoffline': '设备不在线!',
|
|
956
961
|
'operationsuccess': '操作成功',
|
|
957
|
-
'
|
|
962
|
+
'savesuccess': '保存成功!'
|
|
958
963
|
},
|
|
959
964
|
'login': {
|
|
960
965
|
'title': '信号机设备配置',
|
|
@@ -11,6 +11,7 @@
|
|
|
11
11
|
:showBarrier="showBarrier"
|
|
12
12
|
:controlPhase="controlPhase"
|
|
13
13
|
:isShowTip="isShowTip"
|
|
14
|
+
:isMove="isMove"
|
|
14
15
|
:localPatternList="localPatternList"
|
|
15
16
|
:showCondition="showCondition"
|
|
16
17
|
:contrloType="contrloType"
|
|
@@ -24,6 +25,7 @@
|
|
|
24
25
|
:cycle="cycle"
|
|
25
26
|
:syncTime="syncTime"
|
|
26
27
|
:style="{'margin-top': '25px'}"
|
|
28
|
+
@handleSplitMove="handleSplitMove"
|
|
27
29
|
:patternStatusList="patternStatusList"
|
|
28
30
|
:patternId="patternId"
|
|
29
31
|
:cycles="cycles">
|
|
@@ -72,6 +74,10 @@ export default {
|
|
|
72
74
|
stagesChange: {
|
|
73
75
|
type: Array
|
|
74
76
|
},
|
|
77
|
+
isMove: {
|
|
78
|
+
type: Boolean,
|
|
79
|
+
default: true
|
|
80
|
+
},
|
|
75
81
|
isShowTip: {
|
|
76
82
|
type: Boolean,
|
|
77
83
|
default: true
|
|
@@ -108,6 +114,11 @@ export default {
|
|
|
108
114
|
syncTime: {
|
|
109
115
|
type: Number
|
|
110
116
|
}
|
|
117
|
+
},
|
|
118
|
+
methods: {
|
|
119
|
+
handleSplitMove (data) {
|
|
120
|
+
this.$emit('handleSplitMove', data)
|
|
121
|
+
}
|
|
111
122
|
}
|
|
112
123
|
}
|
|
113
124
|
</script>
|
package/src/kisscomps/components/ChannelRealtimeIntersection/ChannelRealtimeIntersection.vue
CHANGED
|
@@ -88,7 +88,7 @@ export default {
|
|
|
88
88
|
getPlatform () {
|
|
89
89
|
queryDevice(this.agentId).then(res => {
|
|
90
90
|
if (!res.data.success) {
|
|
91
|
-
let commomMsg = this.$t('
|
|
91
|
+
let commomMsg = this.$t('openatccomponents.overview.signalID') + ': ' + this.AgentId
|
|
92
92
|
this.$message.error(getMessageByCode(res.data.code, this.$i18n.locale) + ' - ' + commomMsg)
|
|
93
93
|
return
|
|
94
94
|
}
|
package/src/kisscomps/components/IntersectionDirectionSelection/IntersectionDirectionSelection.vue
CHANGED
|
@@ -119,7 +119,7 @@ export default {
|
|
|
119
119
|
getPlatform () {
|
|
120
120
|
queryDevice(this.agentId).then(res => {
|
|
121
121
|
if (!res.data.success) {
|
|
122
|
-
let commomMsg = this.$t('
|
|
122
|
+
let commomMsg = this.$t('openatccomponents.overview.signalID') + ': ' + this.AgentId
|
|
123
123
|
this.$message.error(getMessageByCode(res.data.code, this.$i18n.locale) + ' - ' + commomMsg)
|
|
124
124
|
return
|
|
125
125
|
}
|
|
@@ -233,7 +233,7 @@ export default {
|
|
|
233
233
|
let _this = this
|
|
234
234
|
queryDevice(this.AgentId).then(res => {
|
|
235
235
|
if (!res.data.success) {
|
|
236
|
-
let commomMsg = this.$t('
|
|
236
|
+
let commomMsg = this.$t('openatccomponents.overview.signalID') + ': ' + this.AgentId
|
|
237
237
|
let msg = getMessageByCode(res.data.code, this.$i18n.locale) + ', ' + commomMsg
|
|
238
238
|
this.$message.error(msg)
|
|
239
239
|
return
|
|
@@ -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="58px" Heights="58px" :Datas="styles" :Data="showStyle" :showlist="element.desc" :ISActiveMask="ISActiveMask" :MaskColor="MaskColor"></xdrdirselector>
|
|
54
54
|
</div>
|
|
55
55
|
</el-tooltip>
|
|
56
56
|
</el-col>
|
|
@@ -79,9 +79,13 @@ export default {
|
|
|
79
79
|
},
|
|
80
80
|
data () {
|
|
81
81
|
return {
|
|
82
|
+
showStyle: {
|
|
83
|
+
left: '2px',
|
|
84
|
+
top: '0px'
|
|
85
|
+
},
|
|
82
86
|
styles: {
|
|
83
87
|
left: '1px',
|
|
84
|
-
top: '
|
|
88
|
+
top: '0px'
|
|
85
89
|
},
|
|
86
90
|
typeOptions: [{
|
|
87
91
|
value: 'flow-split-opt'
|
|
@@ -97,6 +101,9 @@ export default {
|
|
|
97
101
|
type: String,
|
|
98
102
|
default: 'Header'
|
|
99
103
|
},
|
|
104
|
+
id: {
|
|
105
|
+
type: Number
|
|
106
|
+
},
|
|
100
107
|
rings: {
|
|
101
108
|
type: Object
|
|
102
109
|
},
|
|
@@ -209,6 +216,7 @@ export default {
|
|
|
209
216
|
}
|
|
210
217
|
}
|
|
211
218
|
}
|
|
219
|
+
this.$emit('optimizesucess', this.id)
|
|
212
220
|
}
|
|
213
221
|
}).catch(error => {
|
|
214
222
|
console.log(error)
|
|
@@ -232,6 +240,7 @@ export default {
|
|
|
232
240
|
}
|
|
233
241
|
}
|
|
234
242
|
}
|
|
243
|
+
this.$emit('optimizesucess', this.id)
|
|
235
244
|
}
|
|
236
245
|
}).catch(error => {
|
|
237
246
|
console.log(error)
|
|
@@ -14,8 +14,9 @@
|
|
|
14
14
|
<!-- 环模式true -->
|
|
15
15
|
<div v-if="this.contrloType === 'ring' || !this.contrloType">
|
|
16
16
|
<div class="ring-first" v-for="(list, index1) in patternInfo" :key="index1">
|
|
17
|
-
<
|
|
18
|
-
<div
|
|
17
|
+
<draggable :move="move" @end="endDrag(index1)" :disabled="isMove" :list="list">
|
|
18
|
+
<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': ''">
|
|
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'}">
|
|
19
20
|
<el-tooltip placement="top-start" effect="light">
|
|
20
21
|
<div slot="content">{{$t('openatccomponents.phase.phase')}}{{item.id}}:{{item.split}}</div>
|
|
21
22
|
<div style="cursor:pointer;">
|
|
@@ -25,7 +26,18 @@
|
|
|
25
26
|
</div>
|
|
26
27
|
<div v-if="isShowTip" class="box" style="position: absolute; left:40px; width:40px; top: -1px;">
|
|
27
28
|
<div class="ring-nums">{{$t('openatccomponents.phase.phase')}}{{item.id}}</div>
|
|
28
|
-
<div class="ring-nums">{{item.split}}</div>
|
|
29
|
+
<div v-if="isMove" class="ring-nums">{{item.split}}</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>
|
|
29
41
|
</div>
|
|
30
42
|
</div>
|
|
31
43
|
</el-tooltip>
|
|
@@ -41,7 +53,8 @@
|
|
|
41
53
|
<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>
|
|
42
54
|
<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>
|
|
43
55
|
<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>
|
|
44
|
-
|
|
56
|
+
</div>
|
|
57
|
+
</draggable>
|
|
45
58
|
</div>
|
|
46
59
|
<div v-if="showBarrier">
|
|
47
60
|
<div v-for="(item, index) in barrierList" :key="index + '1'">
|
|
@@ -100,6 +113,7 @@
|
|
|
100
113
|
<script>
|
|
101
114
|
// import patternwalksvg from '../PatternWalkSvg/PatternWalkSvg'
|
|
102
115
|
import xdrdirselector from '../XRDDirSelector/XRDDirSelector'
|
|
116
|
+
import draggable from 'vuedraggable'
|
|
103
117
|
// import PatternWalkSvg from '../IntersectionMap/crossDirection/baseImg/PatternWalkSvg'
|
|
104
118
|
import PhaseDataModel from '../IntersectionMap/crossDirection/utils.js'
|
|
105
119
|
import CrossDiagramMgr from '../../../EdgeMgr/controller/crossDiagramMgr.js'
|
|
@@ -107,6 +121,7 @@ export default {
|
|
|
107
121
|
name: 'pattern-list',
|
|
108
122
|
components: {
|
|
109
123
|
// patternwalksvg,
|
|
124
|
+
draggable,
|
|
110
125
|
xdrdirselector
|
|
111
126
|
},
|
|
112
127
|
data () {
|
|
@@ -114,6 +129,7 @@ export default {
|
|
|
114
129
|
barrierHeight: '',
|
|
115
130
|
stageCycle: '',
|
|
116
131
|
barrierList: [],
|
|
132
|
+
barrierArr: [],
|
|
117
133
|
newCycle: this.cycles,
|
|
118
134
|
patternIds: this.patternId,
|
|
119
135
|
newPatterns: [],
|
|
@@ -142,6 +158,10 @@ export default {
|
|
|
142
158
|
stagesChange: {
|
|
143
159
|
type: Array
|
|
144
160
|
},
|
|
161
|
+
isMove: {
|
|
162
|
+
type: Boolean,
|
|
163
|
+
default: true
|
|
164
|
+
},
|
|
145
165
|
controlPhase: {
|
|
146
166
|
type: Object
|
|
147
167
|
},
|
|
@@ -343,11 +363,11 @@ export default {
|
|
|
343
363
|
handler: function (val, oldVal) {
|
|
344
364
|
this.handleBarrierHeight() // 计算屏障高度
|
|
345
365
|
if (this.patternStatusList && this.newCycle) {
|
|
346
|
-
setTimeout(() => {
|
|
347
|
-
|
|
348
|
-
this.handleBarrierHeight()
|
|
349
|
-
}, 10)
|
|
366
|
+
// setTimeout(() => {
|
|
367
|
+
this.handleCurrentChange(this.patternStatusList)
|
|
350
368
|
this.handleBarrierHeight()
|
|
369
|
+
// }, 10)
|
|
370
|
+
// this.handleBarrierHeight()
|
|
351
371
|
}
|
|
352
372
|
},
|
|
353
373
|
// 深度观察监听
|
|
@@ -375,6 +395,60 @@ export default {
|
|
|
375
395
|
}
|
|
376
396
|
},
|
|
377
397
|
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
|
+
},
|
|
378
452
|
getPed (data) {
|
|
379
453
|
let ped = []
|
|
380
454
|
for (let stg of data) {
|
|
@@ -1179,6 +1253,7 @@ export default {
|
|
|
1179
1253
|
}
|
|
1180
1254
|
}
|
|
1181
1255
|
let resArr = ringArr.map(item => item.data)
|
|
1256
|
+
this.barrierArr = resArr
|
|
1182
1257
|
let ringTeam = this.step1(this.phaseList, resArr)
|
|
1183
1258
|
let ringTeams = ringTeam.filter(item => item.length !== 0)
|
|
1184
1259
|
if (this.patternList) {
|
|
@@ -599,7 +599,7 @@ export default {
|
|
|
599
599
|
queryDevParams () {
|
|
600
600
|
queryDevice(this.AgentId).then(res => {
|
|
601
601
|
if (!res.data.success) {
|
|
602
|
-
let commomMsg = this.$t('
|
|
602
|
+
let commomMsg = this.$t('openatccomponents.overview.signalID') + ': ' + this.AgentId
|
|
603
603
|
let msg = getMessageByCode(res.data.code, this.$i18n.locale) + ', ' + commomMsg
|
|
604
604
|
this.$message.error(msg)
|
|
605
605
|
return
|
|
@@ -644,7 +644,7 @@ export default {
|
|
|
644
644
|
getPlatform () {
|
|
645
645
|
queryDevice(this.AgentId).then(res => {
|
|
646
646
|
if (!res.data.success) {
|
|
647
|
-
let commomMsg = this.$t('
|
|
647
|
+
let commomMsg = this.$t('openatccomponents.overview.signalID') + ': ' + this.AgentId
|
|
648
648
|
this.$message.error(getMessageByCode(res.data.code, this.$i18n.locale) + ' - ' + commomMsg)
|
|
649
649
|
return
|
|
650
650
|
}
|
|
@@ -25,7 +25,7 @@
|
|
|
25
25
|
<button slot="reference" class="btn" @click="handleEdit" ref="editbtn">{{$t('openatccomponents.greenwaveoptimize.edit')}}</button>
|
|
26
26
|
</el-popover>
|
|
27
27
|
</div>
|
|
28
|
-
<el-button class="btn" type="primary" @click="Download" style="margin-left:10px;">{{$t('
|
|
28
|
+
<el-button class="btn" type="primary" @click="Download" style="margin-left:10px;">{{$t('openatccomponents.button.download')}}</el-button>
|
|
29
29
|
</div>
|
|
30
30
|
<el-tabs v-model="activeName" type="card" @tab-click="handleClick" style="border:0px solid red;height:40%;">
|
|
31
31
|
<el-tab-pane :label="$t('openatccomponents.greenwaveoptimize.timespace')" name="first">
|
|
@@ -292,7 +292,7 @@ export default {
|
|
|
292
292
|
this.$message.error(msg)
|
|
293
293
|
resolve(false)
|
|
294
294
|
}
|
|
295
|
-
this.$message.success(this.$t('
|
|
295
|
+
this.$message.success(this.$t('openatccomponents.common.deletesuccess'))
|
|
296
296
|
this.$parent.getAllPlan()
|
|
297
297
|
resolve(true)
|
|
298
298
|
}).catch(error => {
|
|
@@ -315,7 +315,7 @@ export default {
|
|
|
315
315
|
this.$message.error(msg)
|
|
316
316
|
resolve(false)
|
|
317
317
|
}
|
|
318
|
-
this.$message.success(this.$t('
|
|
318
|
+
this.$message.success(this.$t('openatccomponents.common.savesuccess'))
|
|
319
319
|
this.$parent.getAllPlan()
|
|
320
320
|
resolve(true)
|
|
321
321
|
}).catch(error => {
|
|
@@ -337,7 +337,7 @@ export default {
|
|
|
337
337
|
this.$message.error(msg)
|
|
338
338
|
return
|
|
339
339
|
}
|
|
340
|
-
this.$message.success(this.$t('
|
|
340
|
+
this.$message.success(this.$t('openatccomponents.common.savesuccess'))
|
|
341
341
|
this.$parent.getAllPlan()
|
|
342
342
|
})
|
|
343
343
|
},
|
|
@@ -11,7 +11,7 @@
|
|
|
11
11
|
**/
|
|
12
12
|
<template>
|
|
13
13
|
<div class="openatc-planmanu">
|
|
14
|
-
<div class="title" style="display:flex;">{{$t('
|
|
14
|
+
<div class="title" style="display:flex;">{{$t('openatccomponents.main.routeOptimize')}}</div>
|
|
15
15
|
<el-menu @select="selectPlan" v-loading="loading">
|
|
16
16
|
<el-menu-item :index="String(plan.id)" v-for="(plan, index) in planData" :key="index">
|
|
17
17
|
<span slot="title">{{plan.name}}</span>
|
|
@@ -19,7 +19,7 @@
|
|
|
19
19
|
</el-menu>
|
|
20
20
|
<div class="btnGroup" v-show="false">
|
|
21
21
|
<div class="addbtn" :style="{zIndex: zIndexObj.addZIndex}">
|
|
22
|
-
<button slot="reference" class="btn" @click="onAdd" ref="addbtn">{{$t('
|
|
22
|
+
<button slot="reference" class="btn" @click="onAdd" ref="addbtn">{{$t('openatccomponents.common.add')}}</button>
|
|
23
23
|
</div>
|
|
24
24
|
<div class="operate">
|
|
25
25
|
<el-dropdown trigger="click" @command="switchOperate">
|
|
@@ -27,8 +27,8 @@
|
|
|
27
27
|
{{$t('openatccomponents.greenwaveoptimize.operation')}}<i class="el-icon-arrow-down el-icon--right"></i>
|
|
28
28
|
</span>
|
|
29
29
|
<el-dropdown-menu slot="dropdown">
|
|
30
|
-
<el-dropdown-item icon="el-icon-edit" command="Edit">{{$t('
|
|
31
|
-
<el-dropdown-item icon="el-icon-delete" command="Delete">{{$t('
|
|
30
|
+
<el-dropdown-item icon="el-icon-edit" command="Edit">{{$t('openatccomponents.common.edit')}}</el-dropdown-item>
|
|
31
|
+
<el-dropdown-item icon="el-icon-delete" command="Delete">{{$t('openatccomponents.common.delete')}}</el-dropdown-item>
|
|
32
32
|
</el-dropdown-menu>
|
|
33
33
|
</el-dropdown>
|
|
34
34
|
</div>
|
|
@@ -139,7 +139,7 @@ export default {
|
|
|
139
139
|
this.deleteDiologVisible = false
|
|
140
140
|
this.resetChooseId()
|
|
141
141
|
this.$message({
|
|
142
|
-
message: this.$t('
|
|
142
|
+
message: this.$t('openatccomponents.common.deletesuccess'),
|
|
143
143
|
type: 'success',
|
|
144
144
|
duration: 1 * 1000,
|
|
145
145
|
onClose: () => {
|
|
@@ -168,7 +168,7 @@ export default {
|
|
|
168
168
|
}
|
|
169
169
|
this.closeAddDialog()
|
|
170
170
|
this.$message({
|
|
171
|
-
message: this.$t('
|
|
171
|
+
message: this.$t('openatccomponents.common.updatesuccess'),
|
|
172
172
|
type: 'success',
|
|
173
173
|
duration: 1 * 1000,
|
|
174
174
|
onClose: () => {
|
|
@@ -189,7 +189,7 @@ export default {
|
|
|
189
189
|
}
|
|
190
190
|
this.closeAddDialog()
|
|
191
191
|
this.$message({
|
|
192
|
-
message: this.$t('
|
|
192
|
+
message: this.$t('openatccomponents.common.addsuccess'),
|
|
193
193
|
type: 'success',
|
|
194
194
|
duration: 1 * 1000,
|
|
195
195
|
onClose: () => {
|
|
@@ -5,6 +5,7 @@
|
|
|
5
5
|
:contrloType="contrloType"
|
|
6
6
|
:stagesChange="stagesChange"
|
|
7
7
|
:isShowTip="isShowTip"
|
|
8
|
+
:isMove="isMove"
|
|
8
9
|
:patternStatusList="patternStatusList"
|
|
9
10
|
:cycles="cycles"
|
|
10
11
|
:cycle="cycle"
|
|
@@ -19,6 +20,7 @@
|
|
|
19
20
|
:agentId="agentId"
|
|
20
21
|
:controlData="controlData"
|
|
21
22
|
:syncTime="syncTime"
|
|
23
|
+
@handleSplitMove="handleSplitMove"
|
|
22
24
|
:isPhase="isPhase"
|
|
23
25
|
>
|
|
24
26
|
</BoardCard>
|
|
@@ -502,6 +504,10 @@ export default {
|
|
|
502
504
|
type: Boolean,
|
|
503
505
|
default: true
|
|
504
506
|
},
|
|
507
|
+
isMove: {
|
|
508
|
+
type: Boolean,
|
|
509
|
+
default: true
|
|
510
|
+
},
|
|
505
511
|
contrloType: {
|
|
506
512
|
type: String
|
|
507
513
|
},
|
|
@@ -581,6 +587,11 @@ export default {
|
|
|
581
587
|
// if (this.$route.query !== undefined && Object.keys(this.$route.query).length) {
|
|
582
588
|
// this.resetCrossDiagram()
|
|
583
589
|
// }
|
|
590
|
+
},
|
|
591
|
+
methods: {
|
|
592
|
+
handleSplitMove (data) {
|
|
593
|
+
this.$emit('handleSplitMove', data)
|
|
594
|
+
}
|
|
584
595
|
}
|
|
585
596
|
}
|
|
586
597
|
</script>
|