Browse Source

1

shibei_master
jiangyy 3 years ago
parent
commit
554864d64a
  1. 54
      src/views/modules/workSys/mapConfig.vue

54
src/views/modules/workSys/mapConfig.vue

@ -45,21 +45,25 @@
icon="el-icon-delete" icon="el-icon-delete"
@click="handleSetOffset">设置偏差</el-button> --> @click="handleSetOffset">设置偏差</el-button> -->
<span v-if="showBtn&&hasPolygon"> 经度偏差</span> <span v-if="showBtn&&hasPolygon"> 经度偏差</span>
<el-input v-if="showBtn&&hasPolygon" <el-input-number v-if="showBtn&&hasPolygon"
resize="none" resize="none"
size="small" size="small"
style="width:100px" style="width:200px"
placeholder='请输入经度偏差' :precision="6"
v-model="xOffset"> :step="0.00001"
</el-input> placeholder='请输入经度偏差'
v-model="xOffset">
</el-input-number>
<span v-if="showBtn&&hasPolygon"> 纬度偏差</span> <span v-if="showBtn&&hasPolygon"> 纬度偏差</span>
<el-input v-if="showBtn&&hasPolygon" <el-input-number v-if="showBtn&&hasPolygon"
resize="none" resize="none"
size="small" size="small"
style="width:100px" :precision="6"
placeholder='请输入维度偏差' :step="0.00001"
v-model="yOffset"> style="width:200px"
</el-input> placeholder='请输入维度偏差'
v-model="yOffset">
</el-input-number>
<el-button v-if="showBtn&&hasPolygon" <el-button v-if="showBtn&&hasPolygon"
style="margin-left:10px" style="margin-left:10px"
@ -95,12 +99,11 @@
:visible.sync="dialogVisible" :visible.sync="dialogVisible"
width="50%" width="50%"
:before-close="handleClose"> :before-close="handleClose">
<div> <div class="div_textarea">
<el-input type="textarea" <el-input type="textarea"
:autosize="{ minRows: 4, maxRows: 7}" :autosize="{ minRows: 20, maxRows: 50}"
:rows="5" :rows="20"
resize="none" style="width:600px;height:500px"
style="width:600px"
placeholder='请复制坐标数据' placeholder='请复制坐标数据'
v-model="polygonManullyString"> v-model="polygonManullyString">
</el-input> </el-input>
@ -541,9 +544,15 @@ const vueGis = {
if (element.id_ === this.selAgencyId) { if (element.id_ === this.selAgencyId) {
selectedFeatures.push(element) selectedFeatures.push(element)
let polygon = element.getGeometry();
map.getView().fit(polygon, map.getSize());
this.zoom = map.getView().getZoom() - 2
mapView.setZoom(this.zoom);
} }
}); });
}, },
// //
setMapLocation () { setMapLocation () {
@ -1038,7 +1047,9 @@ export default vueGis;
} }
.div_back { .div_back {
z-index: 10; z-index: 10;
right: 10px;
top: 1px;
position: absolute;
display: flex; display: flex;
} }
.div_tip { .div_tip {
@ -1054,6 +1065,9 @@ export default vueGis;
margin-top: 15px; margin-top: 15px;
width: 100%; width: 100%;
} }
.div_textarea {
text-align: center;
}
</style> </style>
<style> <style>
.ol-overlaycontainer-stopevent { .ol-overlaycontainer-stopevent {

Loading…
Cancel
Save