openatc-components 0.0.95 → 0.0.96-hotfix
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/DrawChannelization/drawsvg/index.draw.vue +2 -1
- package/package/kisscomps/components/DrawChannelization/drawsvg/laneEditPanel.vue +119 -17
- package/package/kissui.min.js +1 -1
- package/package.json +1 -1
- package/src/i18n/language/en.js +2 -2
- package/src/i18n/language/zh.js +1 -1
- package/src/kisscomps/components/DrawChannelization/drawsvg/index.draw.vue +2 -1
- package/src/kisscomps/components/DrawChannelization/drawsvg/laneEditPanel.vue +119 -17
- package/src/router/index.js +2 -2
- package/static/styles/channelizatioon.scss +12 -3
|
@@ -541,7 +541,8 @@ export default {
|
|
|
541
541
|
detectortype: 1, // 检测器类型: 1 车辆检测器 2 行人检测器
|
|
542
542
|
detectorid: undefined,
|
|
543
543
|
occupancythreshold: 80,
|
|
544
|
-
|
|
544
|
+
minflowsaturationthreshold: 30,
|
|
545
|
+
maxflowsaturationthreshold: 70,
|
|
545
546
|
...defaultDetectorParam
|
|
546
547
|
}
|
|
547
548
|
this.curChooseIconIndex = detectoritem.index
|
|
@@ -160,18 +160,45 @@
|
|
|
160
160
|
<el-form-item
|
|
161
161
|
:label="$t('openatccomponents.channelizationmap.occupancythreshold') + ':'"
|
|
162
162
|
prop="intersection">
|
|
163
|
-
<el-input-number :min="0" :max="100" :precision="0" :step="1" :controls="false"
|
|
163
|
+
<!-- <el-input-number :min="0" :max="100" :precision="0" :step="1" :controls="false"
|
|
164
164
|
:value="occupancythreshold" size="mini"
|
|
165
165
|
@change="handleChangeOccuthreshold" />
|
|
166
|
-
<span class="detector-threshold-formtext">%</span>
|
|
166
|
+
<span class="detector-threshold-formtext">%</span> -->
|
|
167
|
+
<el-select :value="occupancythreshold" @change="handleChangeOccuthreshold">
|
|
168
|
+
<el-option
|
|
169
|
+
v-for="item in occupResholdOptions"
|
|
170
|
+
:key="item.value"
|
|
171
|
+
:label="item.label"
|
|
172
|
+
:value="item.value">
|
|
173
|
+
</el-option>
|
|
174
|
+
</el-select>
|
|
167
175
|
</el-form-item>
|
|
168
176
|
<el-form-item
|
|
169
177
|
:label="$t('openatccomponents.channelizationmap.saturationthreshold') + ':'"
|
|
170
178
|
prop="count">
|
|
171
|
-
<el-input-number :min="0" :max="100" :precision="0" :step="1" :controls="false"
|
|
179
|
+
<!-- <el-input-number :min="0" :max="100" :precision="0" :step="1" :controls="false"
|
|
172
180
|
:value="flowsaturationthreshold" size="mini"
|
|
173
181
|
@change="handleChangeFlowthreshold" />
|
|
174
|
-
<span class="detector-threshold-formtext">%</span>
|
|
182
|
+
<span class="detector-threshold-formtext">%</span> -->
|
|
183
|
+
<el-select :value="minflowsaturationthreshold" @change="handleChangeMinFlowthreshold">
|
|
184
|
+
<el-option
|
|
185
|
+
v-for="item in minflowResholdOptions"
|
|
186
|
+
:key="item.value"
|
|
187
|
+
:label="item.label"
|
|
188
|
+
:value="item.value"
|
|
189
|
+
:disabled="item.disabled">
|
|
190
|
+
</el-option>
|
|
191
|
+
</el-select>
|
|
192
|
+
<span class="flow-separator">——</span>
|
|
193
|
+
<el-select :value="maxflowsaturationthreshold" @change="handleChangeMaxFlowthreshold">
|
|
194
|
+
<el-option
|
|
195
|
+
v-for="item in maxflowResholdOptions"
|
|
196
|
+
:key="item.value"
|
|
197
|
+
:label="item.label"
|
|
198
|
+
:value="item.value"
|
|
199
|
+
:disabled="item.disabled">
|
|
200
|
+
</el-option>
|
|
201
|
+
</el-select>
|
|
175
202
|
</el-form-item>
|
|
176
203
|
</el-form>
|
|
177
204
|
</div>
|
|
@@ -373,8 +400,12 @@ export default {
|
|
|
373
400
|
iconclass: 'custom-peddetector',
|
|
374
401
|
name: this.$t('openatccomponents.channelizationmap.pedestriandetector')
|
|
375
402
|
}],
|
|
403
|
+
occupResholdOptions: [],
|
|
404
|
+
minflowResholdOptions: [],
|
|
405
|
+
maxflowResholdOptions: [],
|
|
376
406
|
occupancythreshold: 80,
|
|
377
|
-
|
|
407
|
+
minflowsaturationthreshold: 30,
|
|
408
|
+
maxflowsaturationthreshold: 70
|
|
378
409
|
}
|
|
379
410
|
},
|
|
380
411
|
watch: {
|
|
@@ -394,8 +425,11 @@ export default {
|
|
|
394
425
|
if (data.occupancythreshold !== undefined) {
|
|
395
426
|
this.occupancythreshold = data.occupancythreshold
|
|
396
427
|
}
|
|
397
|
-
if (data.
|
|
398
|
-
this.
|
|
428
|
+
if (data.minflowsaturationthreshold !== undefined) {
|
|
429
|
+
this.minflowsaturationthreshold = data.minflowsaturationthreshold
|
|
430
|
+
}
|
|
431
|
+
if (data.maxflowsaturationthreshold !== undefined) {
|
|
432
|
+
this.maxflowsaturationthreshold = data.maxflowsaturationthreshold
|
|
399
433
|
}
|
|
400
434
|
if (data.flip !== undefined) {
|
|
401
435
|
this.flip = data.flip
|
|
@@ -447,8 +481,9 @@ export default {
|
|
|
447
481
|
if (value === 2) {
|
|
448
482
|
// 行人检测器没有阈值设置
|
|
449
483
|
this.iconObj.occupancythreshold = undefined
|
|
450
|
-
this.iconObj.
|
|
451
|
-
this
|
|
484
|
+
this.iconObj.minflowsaturationthreshold = undefined
|
|
485
|
+
this.iconObj.maxflowsaturationthreshold = undefined
|
|
486
|
+
this.$emit('changeIconDataByType', this.iconObj, ['occupancythreshold', 'minflowsaturationthreshold', 'maxflowsaturationthreshold'])
|
|
452
487
|
}
|
|
453
488
|
},
|
|
454
489
|
selectPedPos (value) {
|
|
@@ -506,15 +541,53 @@ export default {
|
|
|
506
541
|
this.iconObj.occupancythreshold = occupancythreshold
|
|
507
542
|
this.$emit('changeIconDataByType', this.iconObj, ['occupancythreshold'])
|
|
508
543
|
},
|
|
509
|
-
|
|
510
|
-
if (
|
|
544
|
+
handleChangeMinFlowthreshold (minflowsaturationthreshold) {
|
|
545
|
+
if (minflowsaturationthreshold === undefined) {
|
|
546
|
+
this.$message.error(this.$t('openatccomponents.channelizationmap.checkthreshold'))
|
|
547
|
+
this.minflowsaturationthreshold = 30
|
|
548
|
+
return
|
|
549
|
+
}
|
|
550
|
+
this.minflowsaturationthreshold = minflowsaturationthreshold
|
|
551
|
+
this.iconObj.minflowsaturationthreshold = minflowsaturationthreshold
|
|
552
|
+
this.$emit('changeIconDataByType', this.iconObj, ['minflowsaturationthreshold'])
|
|
553
|
+
this.handleDisabledMaxflowOption()
|
|
554
|
+
},
|
|
555
|
+
handleDisabledMinflowOption () {
|
|
556
|
+
// 此处需要排他,恢复上次置灰到默认值
|
|
557
|
+
this.minflowResholdOptions = this.minflowResholdOptions.map(option => ({
|
|
558
|
+
label: option.label,
|
|
559
|
+
value: option.value
|
|
560
|
+
}))
|
|
561
|
+
// 控制流量饱和度最小阈值的禁用范围
|
|
562
|
+
for (let i = 0; i < this.minflowResholdOptions.length; i++) {
|
|
563
|
+
if (this.minflowResholdOptions[i].value >= this.maxflowsaturationthreshold) {
|
|
564
|
+
this.minflowResholdOptions[i].disabled = true
|
|
565
|
+
}
|
|
566
|
+
}
|
|
567
|
+
},
|
|
568
|
+
handleChangeMaxFlowthreshold (maxflowsaturationthreshold) {
|
|
569
|
+
if (maxflowsaturationthreshold === undefined) {
|
|
511
570
|
this.$message.error(this.$t('openatccomponents.channelizationmap.checkthreshold'))
|
|
512
|
-
this.
|
|
571
|
+
this.maxflowsaturationthreshold = 70
|
|
513
572
|
return
|
|
514
573
|
}
|
|
515
|
-
this.
|
|
516
|
-
this.iconObj.
|
|
517
|
-
this.$emit('changeIconDataByType', this.iconObj, ['
|
|
574
|
+
this.maxflowsaturationthreshold = maxflowsaturationthreshold
|
|
575
|
+
this.iconObj.maxflowsaturationthreshold = maxflowsaturationthreshold
|
|
576
|
+
this.$emit('changeIconDataByType', this.iconObj, ['maxflowsaturationthreshold'])
|
|
577
|
+
this.handleDisabledMinflowOption()
|
|
578
|
+
},
|
|
579
|
+
handleDisabledMaxflowOption () {
|
|
580
|
+
// 此处需要排他,恢复上次置灰到默认值
|
|
581
|
+
this.maxflowResholdOptions = this.maxflowResholdOptions.map(option => ({
|
|
582
|
+
label: option.label,
|
|
583
|
+
value: option.value
|
|
584
|
+
}))
|
|
585
|
+
// 控制流量饱和度最大阈值的禁用范围
|
|
586
|
+
for (let i = 0; i < this.maxflowResholdOptions.length; i++) {
|
|
587
|
+
if (this.maxflowResholdOptions[i].value <= this.minflowsaturationthreshold) {
|
|
588
|
+
this.maxflowResholdOptions[i].disabled = true
|
|
589
|
+
}
|
|
590
|
+
}
|
|
518
591
|
},
|
|
519
592
|
getCurPedPosList (iconpedtypeid) {
|
|
520
593
|
// 方位根据行人类型显示
|
|
@@ -532,8 +605,34 @@ export default {
|
|
|
532
605
|
handleChangeFilp (value) {
|
|
533
606
|
this.iconObj.flip = value
|
|
534
607
|
this.$emit('changeIconDataByType', this.iconObj, ['flip'])
|
|
608
|
+
},
|
|
609
|
+
createResholdSelectOptions () {
|
|
610
|
+
for (let i = 5; i < 100; i = i + 5) {
|
|
611
|
+
let option = {
|
|
612
|
+
label: i + '%',
|
|
613
|
+
value: i
|
|
614
|
+
}
|
|
615
|
+
this.occupResholdOptions.push(option)
|
|
616
|
+
if (i <= this.minflowsaturationthreshold) {
|
|
617
|
+
option.disabled = true
|
|
618
|
+
}
|
|
619
|
+
this.maxflowResholdOptions.push(option)
|
|
620
|
+
}
|
|
621
|
+
for (let i = 5; i < 100; i = i + 5) {
|
|
622
|
+
let option = {
|
|
623
|
+
label: i + '%',
|
|
624
|
+
value: i
|
|
625
|
+
}
|
|
626
|
+
if (i >= this.maxflowsaturationthreshold) {
|
|
627
|
+
option.disabled = true
|
|
628
|
+
}
|
|
629
|
+
this.minflowResholdOptions.push(option)
|
|
630
|
+
}
|
|
535
631
|
}
|
|
536
632
|
},
|
|
633
|
+
created () {
|
|
634
|
+
this.createResholdSelectOptions()
|
|
635
|
+
},
|
|
537
636
|
mounted () {
|
|
538
637
|
if (JSON.stringify(this.Data) === '{}') return
|
|
539
638
|
this.iconObj = JSON.parse(JSON.stringify(this.Data))
|
|
@@ -549,8 +648,11 @@ export default {
|
|
|
549
648
|
if (this.Data.occupancythreshold !== undefined) {
|
|
550
649
|
this.occupancythreshold = this.Data.occupancythreshold
|
|
551
650
|
}
|
|
552
|
-
if (this.Data.
|
|
553
|
-
this.
|
|
651
|
+
if (this.Data.minflowsaturationthreshold !== undefined) {
|
|
652
|
+
this.minflowsaturationthreshold = this.Data.minflowsaturationthreshold
|
|
653
|
+
}
|
|
654
|
+
if (this.Data.maxflowsaturationthreshold !== undefined) {
|
|
655
|
+
this.maxflowsaturationthreshold = this.Data.maxflowsaturationthreshold
|
|
554
656
|
}
|
|
555
657
|
if (this.Data.flip !== undefined) {
|
|
556
658
|
this.flip = this.Data.flip
|