地图绘图代码调整
This commit is contained in:
parent
56089e1a55
commit
1e91cb616d
@ -257,11 +257,13 @@ export default {
|
||||
};
|
||||
if (res && res.code === 200) {
|
||||
res.data.forEach(item => {
|
||||
this.trainingOperateTypeMap[item.operateObject].forEach(ele => {
|
||||
if (ele.value == item.operate && !this.checkIncludes(operateTypeMap[item.operateObject], ele)) {
|
||||
operateTypeMap[item.operateObject].push(ele);
|
||||
}
|
||||
});
|
||||
if (this.trainingOperateTypeMap[item.operateObject]) {
|
||||
this.trainingOperateTypeMap[item.operateObject].forEach(ele => {
|
||||
if (ele.value == item.operate && !this.checkIncludes(operateTypeMap[item.operateObject], ele)) {
|
||||
operateTypeMap[item.operateObject].push(ele);
|
||||
}
|
||||
});
|
||||
}
|
||||
if (!trainingOperateList.includes(item.operateObject)) {
|
||||
trainingOperateList.push(item.operateObject);
|
||||
const objectLabel = ConstConfig.ConstSelect.trainingDeviceType[item.operateObject] || {};
|
||||
|
@ -138,13 +138,6 @@ export default {
|
||||
</script>
|
||||
<style rel="stylesheet/scss" lang="scss" scoped>
|
||||
@import "src/styles/mixin.scss";
|
||||
|
||||
.map-context {
|
||||
display: block;
|
||||
float: left;
|
||||
margin-left: 5px;
|
||||
}
|
||||
|
||||
.map-control {
|
||||
float: right;
|
||||
width: 100%;
|
||||
|
@ -658,7 +658,6 @@ export default {
|
||||
}
|
||||
.box{
|
||||
height: 100%;
|
||||
overflow: hidden;
|
||||
}
|
||||
|
||||
.mapPaint{
|
||||
|
@ -2,21 +2,21 @@
|
||||
<transition name="el-zoom-in-center">
|
||||
<div class="map-control">
|
||||
<div class="border-card">
|
||||
<div class="clearfix">
|
||||
<div class="map-operate">
|
||||
<span>
|
||||
{{ $t('map.mapName') }}
|
||||
<b>{{ mapInfo.name }}</b>
|
||||
</span>
|
||||
<el-button v-if="isSave" type="text" style="float: right; padding: 3px 0" :disabled="$attrs.mapSaveing" @click="saveMapEvent">{{ $t('map.save') }}</el-button>
|
||||
<el-dropdown style="float: right; padding: 3px 0; margin-right: 5px;" trigger="click">
|
||||
<el-dropdown class="operate-button" trigger="click">
|
||||
<span class="el-dropdown-link">数据操作</span>
|
||||
<el-dropdown-menu slot="dropdown">
|
||||
<el-dropdown-item><span style="display:block;" :disabled="$attrs.mapSaveing" @click="verifyMapEvent">{{ $t('map.dataVerification') }}</span></el-dropdown-item>
|
||||
<el-dropdown-item><span style="display:block;" :disabled="$attrs.mapSaveing" @click="generateCIEvent">生成联锁</span></el-dropdown-item>
|
||||
</el-dropdown-menu>
|
||||
</el-dropdown>
|
||||
<el-button type="text" style="float: right; padding: 3px 0; margin-right: 5px;" @click="dataRelation">{{ $t('map.advanced') }}</el-button>
|
||||
<el-button type="text" style="float: right; padding: 3px 0; margin-right: 5px;" @click="showMap">绘图显隐</el-button>
|
||||
<el-button type="text" class="operate-button" @click="dataRelation">{{ $t('map.advanced') }}</el-button>
|
||||
<el-button type="text" class="operate-button" @click="showMap">绘图显隐</el-button>
|
||||
</div>
|
||||
<el-tabs v-show="projectType" v-model="enabledTab" class="mapEdit" type="card">
|
||||
<el-tab-pane v-for="(each,index) in tabList" :key="index" :label="each.label" class="tab_pane_box" :name="each.name" :lazy="lazy">
|
||||
@ -190,14 +190,9 @@ export default {
|
||||
this.enabledTab = type;
|
||||
}
|
||||
},
|
||||
|
||||
deviceSelect(type) {
|
||||
this.selectDevice = type;
|
||||
},
|
||||
|
||||
handleSelectLogicalView(handle) {
|
||||
this.$emit('handleSelectLogicalView', handle);
|
||||
},
|
||||
handleSelectPhysicalView(handle) {
|
||||
this.$emit('handleSelectPhysicalView', handle);
|
||||
},
|
||||
@ -215,12 +210,6 @@ export default {
|
||||
</script>
|
||||
<style rel="stylesheet/scss" lang="scss" scoped>
|
||||
@import "src/styles/mixin.scss";
|
||||
|
||||
.map-context {
|
||||
display: block;
|
||||
float: left;
|
||||
margin-left: 5px;
|
||||
}
|
||||
.el-dropdown-link {
|
||||
cursor: pointer;
|
||||
color: #409EFF;
|
||||
@ -229,7 +218,6 @@ export default {
|
||||
font-size: 12px;
|
||||
}
|
||||
.map-control {
|
||||
float: right;
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
.border-card{
|
||||
@ -237,6 +225,12 @@ export default {
|
||||
}
|
||||
}
|
||||
|
||||
.operate-button{
|
||||
float: right;
|
||||
padding: 3px 0;
|
||||
margin-right: 5px;
|
||||
}
|
||||
|
||||
.physical-view {
|
||||
line-height: 25px;
|
||||
height: 118px;
|
||||
@ -249,7 +243,7 @@ export default {
|
||||
}
|
||||
}
|
||||
|
||||
.clearfix{
|
||||
.map-operate{
|
||||
height: 47px;
|
||||
padding: 15px
|
||||
}
|
||||
|
@ -13,30 +13,7 @@
|
||||
</el-tab-pane>
|
||||
<el-tab-pane class="view-control" :label="$t('map.newConstruction')" name="second" :lazy="lazy">
|
||||
<div class="view-control-content">
|
||||
<el-form ref="make" label-width="150px" :rules="createRules" :model="addModel" size="mini">
|
||||
<el-form-item :label="$t('map.statusSignalName')" prop="name">
|
||||
<el-input v-model="addModel.name" />
|
||||
</el-form-item>
|
||||
<div class="coordinate">
|
||||
<span class="title">{{ $t('map.stateSignalsPlotCoordinates') }}</span>
|
||||
<el-form-item
|
||||
label="x:"
|
||||
prop="position.x"
|
||||
style="display: table; float: left; margin-right: 20px;"
|
||||
label-width="20px"
|
||||
>
|
||||
<el-input-number v-model="addModel.position.x" />
|
||||
</el-form-item>
|
||||
<el-form-item
|
||||
label="y:"
|
||||
prop="position.y"
|
||||
style="display: table; float: left;"
|
||||
label-width="20px"
|
||||
>
|
||||
<el-input-number v-model="addModel.position.y" />
|
||||
</el-form-item>
|
||||
</div>
|
||||
</el-form>
|
||||
<config-data ref="make" :form="createForm" :form-model="addModel" :rules="createRules" />
|
||||
</div>
|
||||
<div class="button_box">
|
||||
<el-button-group class="map-draft-group">
|
||||
@ -51,12 +28,14 @@
|
||||
import { mapGetters } from 'vuex';
|
||||
import { getUID } from '@/jmapNew/utils/Uid';
|
||||
import ConfigList from './config/list';
|
||||
import ConfigData from './config/data';
|
||||
import { deepAssign } from '@/utils/index';
|
||||
|
||||
export default {
|
||||
name: 'LcControlDraft',
|
||||
components: {
|
||||
ConfigList
|
||||
ConfigList,
|
||||
ConfigData
|
||||
},
|
||||
props: {
|
||||
selected: {
|
||||
@ -150,6 +129,19 @@ export default {
|
||||
}
|
||||
};
|
||||
return form;
|
||||
},
|
||||
createForm() {
|
||||
const form = {
|
||||
labelWidth: '150px',
|
||||
items: [
|
||||
{ prop: 'name', label: this.$t('map.statusSignalName'), type: 'input' },
|
||||
{ prop: 'position', label: this.$t('map.stateSignalsPlotCoordinates'), type: 'coordinate', width: '150px', children: [
|
||||
{ prop: 'position.x', firstLevel: 'position', secondLevel: 'x', label: 'x:', type: 'number', labelWidth: '20px', disabled: false },
|
||||
{ prop: 'position.y', firstLevel: 'position', secondLevel: 'y', label: 'y:', type: 'number', labelWidth: '20px', disabled: false }
|
||||
] }
|
||||
]
|
||||
};
|
||||
return form;
|
||||
}
|
||||
},
|
||||
mounted() {
|
||||
|
Loading…
Reference in New Issue
Block a user