fix:增加删除地图选中事件对象
This commit is contained in:
parent
7d6f503c77
commit
6275e6a29e
@ -2,7 +2,7 @@
|
|||||||
* @Author: SunTao 328867980@qq.com
|
* @Author: SunTao 328867980@qq.com
|
||||||
* @Date: 2024-10-14 10:46:23
|
* @Date: 2024-10-14 10:46:23
|
||||||
* @LastEditors: SunTao 328867980@qq.com
|
* @LastEditors: SunTao 328867980@qq.com
|
||||||
* @LastEditTime: 2025-03-31 13:02:21
|
* @LastEditTime: 2025-04-14 09:54:46
|
||||||
* @FilePath: \znxjxt-ui\src\components\map\fssm-map.vue
|
* @FilePath: \znxjxt-ui\src\components\map\fssm-map.vue
|
||||||
* @Description: 公共地图
|
* @Description: 公共地图
|
||||||
-->
|
-->
|
||||||
@ -541,6 +541,18 @@ export default {
|
|||||||
this.selectSingClick.getFeatures().clear();
|
this.selectSingClick.getFeatures().clear();
|
||||||
},
|
},
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @description: 清除地图上的选中事件
|
||||||
|
* @return {void}
|
||||||
|
*/
|
||||||
|
clearSelectInteraction() {
|
||||||
|
if (this.selectSingClick) {
|
||||||
|
const map = this.instance.get("map");
|
||||||
|
map.removeInteraction(this.selectSingClick);
|
||||||
|
this.selectSingClick = null;
|
||||||
|
}
|
||||||
|
},
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @description: 绘制多边形地图
|
* @description: 绘制多边形地图
|
||||||
* @return {*}
|
* @return {*}
|
||||||
|
|||||||
@ -2,7 +2,7 @@
|
|||||||
* @Author: SunTao 328867980@qq.com
|
* @Author: SunTao 328867980@qq.com
|
||||||
* @Date: 2025-03-25 11:10:16
|
* @Date: 2025-03-25 11:10:16
|
||||||
* @LastEditors: SunTao 328867980@qq.com
|
* @LastEditors: SunTao 328867980@qq.com
|
||||||
* @LastEditTime: 2025-04-10 17:22:39
|
* @LastEditTime: 2025-04-14 09:28:11
|
||||||
* @FilePath: \znxjxt-ui\src\views\xj\inspection\map-diease\index.vue
|
* @FilePath: \znxjxt-ui\src\views\xj\inspection\map-diease\index.vue
|
||||||
* @Description: 地图展示筛选病害-首页
|
* @Description: 地图展示筛选病害-首页
|
||||||
-->
|
-->
|
||||||
@ -98,8 +98,8 @@
|
|||||||
ref="mapDieaseMap"
|
ref="mapDieaseMap"
|
||||||
class="map-diease-map"
|
class="map-diease-map"
|
||||||
:maxZoom="24"
|
:maxZoom="24"
|
||||||
@feature-select="featureSelect"
|
|
||||||
></fssm-map>
|
></fssm-map>
|
||||||
|
<!-- @feature-select="featureSelect" -->
|
||||||
<!-- 查看弹窗 -->
|
<!-- 查看弹窗 -->
|
||||||
<el-dialog
|
<el-dialog
|
||||||
title="查看"
|
title="查看"
|
||||||
@ -172,6 +172,10 @@ export default {
|
|||||||
this.getSegmentList();
|
this.getSegmentList();
|
||||||
this.getTableList();
|
this.getTableList();
|
||||||
},
|
},
|
||||||
|
mounted() {
|
||||||
|
// 去除选择事件
|
||||||
|
this.$refs.mapDieaseMap.clearSelectInteraction();
|
||||||
|
},
|
||||||
methods: {
|
methods: {
|
||||||
/**
|
/**
|
||||||
* @description: 获取路段下拉数据
|
* @description: 获取路段下拉数据
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user