desc: 修改地图绘制图层配置, 调整道岔时间显示

This commit is contained in:
zyy 2019-08-19 11:18:46 +08:00
parent 44aa6442f0
commit 138dfe5e06
8 changed files with 29 additions and 28 deletions

View File

@ -410,8 +410,8 @@ export default {
switchShowName: '是否显示道岔名称:',
switchPositionX: '道岔名称x偏移量:',
switchPositionY: '道岔名称y偏移量:',
turnTime: '道岔时间:',
timeoutShow: '是否显示道岔时间:',
turnTime: '道岔转换时间:',
timeoutShow: '是否显示道岔倒计时时间:',
sectionACode: '关联的A Section Code:',
sectionBCode: '关联的B Section Code:',
sectionCCode: '关联的C Section Code:',

View File

@ -97,7 +97,7 @@ export default {
switchNamePointX: '请输入道岔名称坐标x',
switchNamePointY: '请输入道岔名称坐标y',
switchStationCode: '请输入设备集中站',
switchTurnTime: '请输入道岔时间',
switchTurnTime: '请输入道岔转换时间',
switchTpX: '请输入时间坐标x',
switchTpY: '请输入时间坐标y',

View File

@ -333,8 +333,8 @@ export default {
switchShowName: '是否显示道岔名称:',
switchPositionX: '道岔名称x偏移量:',
switchPositionY: '道岔名称y偏移量:',
turnTime: '道岔时间:',
timeoutShow: '是否显示道岔时间:',
turnTime: '道岔转换时间:',
timeoutShow: '是否显示道岔倒计时时间:',
sectionACode: '关联的A Section Code:',
sectionBCode: '关联的B Section Code:',
sectionCCode: '关联的C Section Code:',

View File

@ -97,7 +97,7 @@ export default {
switchNamePointX: '请输入道岔名称坐标x',
switchNamePointY: '请输入道岔名称坐标y',
switchStationCode: '请输入设备集中站',
switchTurnTime: '请输入道岔时间',
switchTurnTime: '请输入道岔转换时间',
switchTpX: '请输入时间坐标x',
switchTpY: '请输入时间坐标y',

View File

@ -65,7 +65,7 @@ export default class Switch extends Group {
const point2 = [point1[0] + directx * switchWidth / this.triangle.getSinRate(), point1[1]];
const point3 = [point2[0] + directx * this.triangle.getCotRate() * swPadding, point2[1] + directy * swPadding];
const point4 = [point3[0] + direct * this.triangle.getSin(switchWidth), point3[1] - direct * this.triangle.getCos(switchWidth)];
this.locShelter = new ESwLocal({
this.locShelter = new ESwLocal({ // 定位
zlevel: this.zlevel,
z: this.z,
style: style,
@ -92,7 +92,7 @@ export default class Switch extends Group {
const spoint3 = [model.intersection.x - directx * width3, model.intersection.y + directy * switchWidth1];
const spoint4 = [spoint1[0] + directx * (width2 + width1) - directx * width3, spoint3[1]];
this.relocShelter = new ESwLnversion({
this.relocShelter = new ESwLnversion({ // 反位
zlevel: this.zlevel,
z: this.z,
style: style,
@ -148,7 +148,7 @@ export default class Switch extends Group {
createLockRect() {
const offsetX = this.model.locateType == '01' ? 3 : 0;
this.lockRect = new ELockRect({
this.lockRect = new ELockRect({ // 锁定矩形
zlevel: this.zlevel,
z: this.z + 6,
x: this.model.intersection.x - this.style.Switch.monolock.rectWidth / 2 + offsetX,

View File

@ -272,8 +272,8 @@ export const attribute = {
{ prop: 'nameShow', label: '是否显示道岔名称:', type: 'checkbox' },
{ prop: 'namePoint.x', firstLevel: 'namePoint', secondLevel: 'x', label: '道岔名称x偏移量:', type: 'number', placeholder: 'px' },
{ prop: 'namePoint.y', firstLevel: 'namePoint', secondLevel: 'y', label: '道岔名称y偏移量:', type: 'number', placeholder: 'px' },
{ prop: 'turnTime', label: '道岔时间:', type: 'number', min: 0, max: 1000, placeholder: 's' },
{ prop: 'timeoutShow', label: '是否显示道岔时间:', type: 'checkbox' },
{ prop: 'turnTime', label: '道岔转换时间:', type: 'number', min: 0, max: 1000, placeholder: 's' },
{ prop: 'timeoutShow', label: '是否显示道岔倒计时时间:', type: 'checkbox' },
{ prop: 'sectionACode', label: '关联的A Section Code:', type: 'select', optionLabel: 'name&&code', optionValue: 'code', options: [], optionCode: 'sectionList' },
{ prop: 'sectionBCode', label: '关联的B Section Code:', type: 'select', optionLabel: 'name&&code', optionValue: 'code', options: [], optionCode: 'sectionList' },
{ prop: 'sectionCCode', label: '关联的C Section Code:', type: 'select', optionLabel: 'name&&code', optionValue: 'code', options: [], optionCode: 'sectionList' },
@ -297,7 +297,7 @@ export const attribute = {
{ required: true, message: '请输入设备集中站', trigger: 'change' }
],
turnTime: [
{ required: true, message: '请输入道岔时间', trigger: 'blur' }
{ required: true, message: '请输入道岔转换时间', trigger: 'blur' }
],
'tp.x': [
{ required: true, message: '请输入时间坐标x', trigger: 'blur' }

View File

@ -1,30 +1,28 @@
<template>
<!-- <el-dialog title="地图显示" :visible.sync="dialogTableVisible" :modal="false" width="460px" top="110px" right="0" custom-class="dialog-box" :close-on-click-modal="false"> -->
<transition name="fade">
<div v-show="dialogTableVisible" class="dialog-box">
<div class="title">
<div class="fl-title">图显示</div>
<div class="fl-title">显示</div>
<div class="fr-title" @click="doClose">
<i class="el-icon-close" />
</div>
</div>
<el-row type="flex" justify="center">
<el-form label-width="100px" class="demo-ruleForm">
<el-form-item label="视图显示" prop="name">
<el-radio-group v-model="viewSelect" @change="handleSelectView">
<el-radio-button :label="ViewMode.LOGIC">{{ $t('map.logicalView') }}</el-radio-button>
<el-radio-button :label="ViewMode.PHYSICAL">{{ $t('map.physicalView') }}</el-radio-button>
<el-radio-button :label="ViewMode.MIX">{{ $t('map.mixedView') }}</el-radio-button>
</el-radio-group>
<el-form-item label="视图显示">
<el-checkbox-group v-model="viewSelect" :min="1" @change="handleSelectView">
<el-checkbox :label="ViewMode.LOGIC">{{ $t('map.logicalView') }}</el-checkbox>
<el-checkbox :label="ViewMode.PHYSICAL">{{ $t('map.physicalView') }}</el-checkbox>
</el-checkbox-group>
</el-form-item>
<el-form-item label="内容显示" prop="name">
<el-row v-if="ViewMode.LOGIC === viewSelect" class="logical-view" type="flex" justify="center" style="width: 100%;">
<el-form-item label="内容显示">
<el-row v-if="ViewMode.LOGIC === viewSelect[0] && viewSelect.length == 1" class="logical-view" type="flex" justify="center" style="width: 100%;">
<el-checkbox-group v-model="logicalLevelsSelect" @change="handleSelectLogicalView">
<el-checkbox v-for="view in LogicalViewTypeList" :key="view.code" :label="view.code" size="mini">
{{ view.name }}</el-checkbox>
</el-checkbox-group>
</el-row>
<el-row v-if="ViewMode.PHYSICAL === viewSelect" class="physical-view" type="flex" justify="center" style="width: 100%;">
<el-row v-if="ViewMode.PHYSICAL === viewSelect[0] && viewSelect.length == 1" class="physical-view" type="flex" justify="center" style="width: 100%;">
<el-checkbox-group v-model="physicalLevelsSelect" @change="handleSelectPhysicalView">
<el-checkbox v-for="view in PhysicalViewTypeList" :key="view.code" :label="view.code">
{{ view.name }}</el-checkbox>
@ -35,7 +33,6 @@
</el-row>
</div>
</transition>
<!-- </el-dialog> -->
</template>
<script>
@ -47,7 +44,7 @@ export default {
return {
ViewMode: ViewMode,
dialogTableVisible: false,
viewSelect: ViewMode.MIX,
viewSelect: [ViewMode.LOGIC, ViewMode.PHYSICAL],
LogicalViewTypeList: [
{ code: 'Link', name: this.$t('map.link') }
],
@ -89,8 +86,12 @@ export default {
});
});
},
handleSelectView(handle) {
this.$emit('handleSelectView', handle);
handleSelectView(value) {
if (value.length == 2) {
this.$emit('handleSelectView', '03');
} else {
this.$emit('handleSelectView', value);
}
},
handleSelectLogicalView(handle) {
this.$emit('handleSelectLogicalView', handle);

View File

@ -106,7 +106,7 @@ export default {
{ prop: 'nameShow', label: this.$t('map.switchShowName'), type: 'checkbox' },
{ prop: 'namePoint.x', firstLevel: 'namePoint', secondLevel: 'x', label: this.$t('map.switchPositionX'), type: 'number', placeholder: 'px' },
{ prop: 'namePoint.y', firstLevel: 'namePoint', secondLevel: 'y', label: this.$t('map.switchPositionY'), type: 'number', placeholder: 'px' },
{ prop: 'timeoutShow', label: this.$t('map.timeoutShow'), type: 'checkbox' },
// { prop: 'timeoutShow', label: this.$t('map.timeoutShow'), type: 'checkbox' },
{ prop: 'tp.x', firstLevel: 'tp', secondLevel: 'x', label: this.$t('map.switchTpX'), type: 'number', placeholder: 'px' },
{ prop: 'tp.y', firstLevel: 'tp', secondLevel: 'y', label: this.$t('map.switchTpY'), type: 'number', placeholder: 'px' }
]