From b04816ec6bffbdc84dfe44aff256ec38f49e4dcf Mon Sep 17 00:00:00 2001 From: Surpriseplus <845948745@qq.com> Date: 星期一, 20 二月 2023 14:45:53 +0800 Subject: [PATCH] 数据申请界面修改 --- src/views/Tools/LayerTree.vue | 35 ++++++++++++++++++++++++++++++++++- 1 files changed, 34 insertions(+), 1 deletions(-) diff --git a/src/views/Tools/LayerTree.vue b/src/views/Tools/LayerTree.vue index 0c41e2e..c924ce0 100644 --- a/src/views/Tools/LayerTree.vue +++ b/src/views/Tools/LayerTree.vue @@ -70,6 +70,12 @@ > <i class="el-icon-edit"></i> 淇敼鑺傜偣 </div> + <div + class="edit" + @click="showLayerAttribute()" + > + <i class="el-icon-edit"></i> 灞炴�� + </div> <!-- <div class="edit" @click="menuMoveF( 'up')" @@ -137,6 +143,7 @@ >纭� 瀹�</el-button> </span> </el-dialog> + <queryinfo ref="queryinfo" /> </div> </template> @@ -146,7 +153,7 @@ import Image from 'ol/layer/Image'; import GeoJSON from 'ol/format/GeoJSON.js'; import Map from 'ol/Map.js'; - +import queryinfo from './queryinfo.vue'; import { Vector as VectorSource } from "ol/source"; import { Vector as VectorLayer, } from "ol/layer"; @@ -155,6 +162,7 @@ import { perms_selectLayers } from '../../api/api.js' export default { name: 'tree', + components: { queryinfo }, data() { return { eleId: '', @@ -332,7 +340,29 @@ this.$refs.tree.remove(this.currentNode); }, + //灞炴�ф樉绀� + showLayerAttribute(data) { + this.foo(); + this.currentData = data ? data : this.currentData; + var layer = this.currentData.layer.replaceAll('_', ""); + this.$store.state.mapSpaceQueryLayer = layer; + // this.$store.state.mapPopBoolean = true; + this.$store.state.mapPopBoxFlag = '2'; + this.$refs && this.$refs.queryinfo && this.$refs.queryinfo.close(); + this.$refs && this.$refs.queryinfo && this.$refs.queryinfo.open("灞炴��", null, { + close: () => { + if (this.$store.state.primitLayer != null) { + sgworld.Creator.DeleteObject(this.$store.state.primitLayer); + this.$store.state.primitLayer = null; + } + + if (window.Viewer.scene.primitives.length != 0) { + window.Viewer.scene.primitives.removeAll() + } + } + }); + }, // 缂栬緫鑺傜偣 editNode(data) { @@ -536,6 +566,7 @@ return this.$message.error("鍥惧眰鍒楄〃鏌ヨ澶辫触"); } + this.newData = data.result; this.oriData = data.result; var std = []; @@ -553,6 +584,7 @@ } else if (data.result[i].type == 2) { if (data.result[i].url != null) { + var layer_entity = { id: data.result[i].id, pid: data.result[i].pid, @@ -560,6 +592,7 @@ resource: data.result[i].url, type: data.result[i].type, isEdit: false, + layer: data.result[i].enName, layerType: data.result[i].serveType } layer_list.push(layer_entity) -- Gitblit v1.9.3