| | |
| | | <mapinfo ref="mapinfo" /> |
| | | <maplayer ref="maplayer" /> |
| | | <queryinfo ref="queryinfo" /> |
| | | <terrainDig ref="terrainDig" /> |
| | | <input |
| | | type="file" |
| | | accept=".kml" |
| | |
| | | import mapinfo from "../Tools/mapinfo.vue"; |
| | | import maplayer from "../Tools/maplayer.vue"; |
| | | import queryinfo from "../Tools/queryinfo.vue"; |
| | | import terrainDig from "../Tools/terrainDig.vue"; |
| | | import $ from "jquery"; |
| | | import { getToken } from "@/utils/auth"; |
| | | import ImageWMS from "ol/source/ImageWMS"; |
| | |
| | | import { geometry } from "@turf/turf"; |
| | | |
| | | export default { |
| | | components: { mapinfo, maplayer, queryinfo }, |
| | | components: { mapinfo, maplayer, queryinfo, terrainDig }, |
| | | data() { |
| | | return { |
| | | showTwoMenuFlag: false, |
| | |
| | | } |
| | | |
| | | if (this.isMenuFlag != val) { |
| | | this.$store.state.mapMenuBoolean = false; |
| | | this.$store.state.mapMenuBoxFlag = null; |
| | | this.$store.state.mapPopBoolean = false; |
| | | this.$store.state.mapPopBoxFlag = null; |
| | | sgworld.Creator.SimpleGraphic.clear(); |
| | | this.isMenuFlag = val; |
| | | if (this.entityaLayers.length != 0) { |
| | | for (var i in this.entityaLayers) { |
| | | sgworld.Viewer.entities.remove(this.entityaLayers[i]); |
| | | if (res.id != 'b9') { |
| | | this.$store.state.mapMenuBoolean = false; |
| | | this.$store.state.mapMenuBoxFlag = null; |
| | | this.$store.state.mapPopBoolean = false; |
| | | this.$store.state.mapPopBoxFlag = null; |
| | | sgworld.Creator.SimpleGraphic.clear(); |
| | | this.isMenuFlag = val; |
| | | if (this.entityaLayers.length != 0) { |
| | | for (var i in this.entityaLayers) { |
| | | sgworld.Viewer.entities.remove(this.entityaLayers[i]); |
| | | } |
| | | this.entityaLayers = []; |
| | | } |
| | | this.entityaLayers = []; |
| | | for (var i in this.$store.state.queryInfo) { |
| | | sgworld.Viewer.entities.remove(this.$store.state.queryInfo[i]); |
| | | } |
| | | this.$store.state.queryInfo = []; |
| | | if (this.$store.state.primitLayer != null) { |
| | | sgworld.Viewer.entities.remove(this.$store.state.primitLayer); |
| | | sgworld.Creator.DeleteObject(this.$store.state.primitLayer); |
| | | this.$store.state.primitLayer = null; |
| | | } |
| | | } |
| | | for (var i in this.$store.state.queryInfo) { |
| | | sgworld.Viewer.entities.remove(this.$store.state.queryInfo[i]); |
| | | } |
| | | this.$store.state.queryInfo = []; |
| | | if (this.$store.state.primitLayer != null) { |
| | | sgworld.Viewer.entities.remove(this.$store.state.primitLayer); |
| | | sgworld.Creator.DeleteObject(this.$store.state.primitLayer); |
| | | this.$store.state.primitLayer = null; |
| | | } |
| | | |
| | | } |
| | | this.showTwoMenuFlag = res.id; |
| | | |
| | |
| | | PDelevationTool.type = "none"; |
| | | } |
| | | PDelevationTool.render(); |
| | | debugger |
| | | |
| | | break; |
| | | case "d3": //路径分析 |
| | | |
| | |
| | | break; |
| | | |
| | | case "d11": //地形开挖 |
| | | if (window.Excavation) { |
| | | window.Excavation.drawHandler && |
| | | window.Excavation.drawHandler.destroy(); |
| | | Viewer._container.style.cursor = "default"; |
| | | window.Excavation.tooltip && window.Excavation.tooltip.show(false); |
| | | window.Excavation.clear(); |
| | | window.Excavation = null; |
| | | } else { |
| | | window.Excavation = sgworld.Analysis.TerrainExcavation( |
| | | 10, |
| | | {}, |
| | | function () { } |
| | | ); |
| | | } |
| | | this.$refs && |
| | | this.$refs.terrainDig && |
| | | this.$refs.terrainDig.open("管道空间分析", null, { |
| | | close: () => { |
| | | |
| | | }, |
| | | }); |
| | | // if (window.Excavation) { |
| | | // window.Excavation.drawHandler && |
| | | // window.Excavation.drawHandler.destroy(); |
| | | // Viewer._container.style.cursor = "default"; |
| | | // window.Excavation.tooltip && window.Excavation.tooltip.show(false); |
| | | // window.Excavation.clear(); |
| | | // window.Excavation = null; |
| | | // } else { |
| | | // window.Excavation = sgworld.Analysis.TerrainExcavation( |
| | | // 10, |
| | | // {}, |
| | | // function () { } |
| | | // ); |
| | | // } |
| | | break; |
| | | |
| | | case "d12": //通视分析 |
| | |
| | | pointSelect: true, |
| | | spood: 20, |
| | | GroupID: 0, |
| | | url: "/SmartEarthSDK/Workers/image/waterNormals.jpg", |
| | | url: "/SmartEarthSDK/Workers/image/33.gif", |
| | | }; |
| | | window.AnalysisFlood = sgworld.Command.execute( |
| | | 2, |