安保活动地图选点优化,系统 相关console.log 去除
| | |
| | | }) |
| | | |
| | | //加载地图 |
| | | global.viewer.imageryLayers.addImageryProvider( |
| | | new global.DC.Namespace.Cesium.UrlTemplateImageryProvider({ |
| | | url: 'https://webmap-tile.sf-express.com/MapTileService/rt?fetchtype=static&x={x}&y={y}&z={z}&project=sfmap&pic_size=256&pic_type=png8&data_name=361100&data_format=merged-dat&data_type=normal', |
| | | format: 'image/jpeg', |
| | | show: true, |
| | | maximumLevel: 18 |
| | | }) |
| | | ) |
| | | |
| | | // global.viewer.imageryLayers.addImageryProvider( |
| | | // new global.DC.Namespace.Cesium.WebMapTileServiceImageryProvider({ |
| | | // url: "http://10.141.11.11:8090/MapTileService/wmts?STORETYPE=merged-dat&PROJECTION=4326", |
| | | // layer: "wmts_4326_361100", |
| | | // style: "default", |
| | | // format: "image/png", |
| | | // tileMatrixSetID: "c", |
| | | // tileMatrixLabels: new Array(18).fill(0).map((v, i) => i + 1), |
| | | // tilingScheme: new global.DC.Namespace.Cesium.GeographicTilingScheme(), |
| | | // global.viewer.imageryLayers.addImageryProvider( |
| | | // new global.DC.Namespace.Cesium.UrlTemplateImageryProvider({ |
| | | // url: 'https://webmap-tile.sf-express.com/MapTileService/rt?fetchtype=static&x={x}&y={y}&z={z}&project=sfmap&pic_size=256&pic_type=png8&data_name=361100&data_format=merged-dat&data_type=normal', |
| | | // format: 'image/jpeg', |
| | | // show: true, |
| | | // maximumLevel: 18 |
| | | // }) |
| | | // ) |
| | | // ) |
| | | |
| | | global.viewer.imageryLayers.addImageryProvider( |
| | | new global.DC.Namespace.Cesium.WebMapTileServiceImageryProvider({ |
| | | url: "http://10.141.11.11:8090/MapTileService/wmts?STORETYPE=merged-dat&PROJECTION=4326", |
| | | layer: "wmts_4326_361100", |
| | | style: "default", |
| | | format: "image/png", |
| | | tileMatrixSetID: "c", |
| | | tileMatrixLabels: new Array(18).fill(0).map((v, i) => i + 1), |
| | | tilingScheme: new global.DC.Namespace.Cesium.GeographicTilingScheme(), |
| | | }) |
| | | ) |
| | | |
| | | //添加图层 |
| | | self.polygonLayer = new global.DC.VectorLayer('polygonLayer') |
| | |
| | | }) |
| | | |
| | | //加载地图 |
| | | global.searchViewer.imageryLayers.addImageryProvider( |
| | | new global.DC.Namespace.Cesium.UrlTemplateImageryProvider({ |
| | | url: 'https://webmap-tile.sf-express.com/MapTileService/rt?fetchtype=static&x={x}&y={y}&z={z}&project=sfmap&pic_size=256&pic_type=png8&data_name=361100&data_format=merged-dat&data_type=normal', |
| | | format: 'image/jpeg', |
| | | show: true, |
| | | maximumLevel: 18 |
| | | }) |
| | | ) |
| | | |
| | | // global.searchViewer.imageryLayers.addImageryProvider( |
| | | // new global.DC.Namespace.Cesium.WebMapTileServiceImageryProvider({ |
| | | // url: "http://10.141.11.11:8090/MapTileService/wmts?STORETYPE=merged-dat&PROJECTION=4326", |
| | | // layer: "wmts_4326_361100", |
| | | // style: "default", |
| | | // format: "image/png", |
| | | // tileMatrixSetID: "c", |
| | | // tileMatrixLabels: new Array(18).fill(0).map((v, i) => i + 1), |
| | | // tilingScheme: new global.DC.Namespace.Cesium.GeographicTilingScheme(), |
| | | // new global.DC.Namespace.Cesium.UrlTemplateImageryProvider({ |
| | | // url: 'https://webmap-tile.sf-express.com/MapTileService/rt?fetchtype=static&x={x}&y={y}&z={z}&project=sfmap&pic_size=256&pic_type=png8&data_name=361100&data_format=merged-dat&data_type=normal', |
| | | // format: 'image/jpeg', |
| | | // show: true, |
| | | // maximumLevel: 18 |
| | | // }) |
| | | // ) |
| | | |
| | | global.searchViewer.imageryLayers.addImageryProvider( |
| | | new global.DC.Namespace.Cesium.WebMapTileServiceImageryProvider({ |
| | | url: "http://10.141.11.11:8090/MapTileService/wmts?STORETYPE=merged-dat&PROJECTION=4326", |
| | | layer: "wmts_4326_361100", |
| | | style: "default", |
| | | format: "image/png", |
| | | tileMatrixSetID: "c", |
| | | tileMatrixLabels: new Array(18).fill(0).map((v, i) => i + 1), |
| | | tilingScheme: new global.DC.Namespace.Cesium.GeographicTilingScheme(), |
| | | }) |
| | | ) |
| | | |
| | | //添加图层 |
| | | pointLayer = new global.DC.VectorLayer('polygonLayer') |
| | | global.searchViewer.addLayer(pointLayer) |
| | |
| | | this.longitude = data[0] |
| | | this.latitude = data[1] |
| | | this.$emit("getLonLat", data) |
| | | |
| | | }, |
| | | remoteMethod(data) { |
| | | this.queryString = data |
| | |
| | | let location = this.longitude + " " + this.latitude |
| | | searchByLonLat(ak, query, region, region_type, page_size, page_num, infos, radius, location).then(res => { |
| | | let data = res.data.result[0] |
| | | this.queryString = data.address |
| | | this.$emit("getAddress", this.queryString) |
| | | if(data!=undefined){ |
| | | this.queryString = data.address |
| | | this.$emit("getAddress", this.queryString) |
| | | let point = [data.location.lng,data.location.lat] |
| | | this.$emit("getLonLat", point) |
| | | //清空 |
| | | this.searchList = [] |
| | | //触发搜索 |
| | | this.getAddressByQuery() |
| | | }else{ |
| | | this.queryString = []; |
| | | //清空 |
| | | this.searchList = [] |
| | | this.$emit("getAddress", '') |
| | | this.$emit("getLonLat", ['','']) |
| | | } |
| | | |
| | | }) |
| | | }, |
| | | selectChange(data) { |
| | |
| | | return new Promise((resolve, reject) => { |
| | | loginByUsername(userInfo.tenantId, userInfo.deptId, userInfo.roleId, userInfo.username, md5(userInfo.password), userInfo.type, userInfo.key, userInfo.code).then(res => { |
| | | const data = res.data |
| | | console.log(data, userInfo, 489) |
| | | if (data.error_description) { |
| | | Message({ |
| | | message: data.error_description, |
| | |
| | | } else if (obj.dataType == 'object') { |
| | | content = obj.content; |
| | | } |
| | | console.log(content,9999) |
| | | return content; |
| | | } |
| | | /** |
| | |
| | | this.chosePoint.address = data |
| | | }, |
| | | confirmLonLat(){ |
| | | this.form.longitude = this.chosePoint.longitude |
| | | this.form.latitude = this.chosePoint.latitude |
| | | this.form.place = this.chosePoint.address |
| | | this.point = "POINT("+this.form.longitude +" "+this.form.latitude+")" |
| | | this.placeBox = false |
| | | if(this.chosePoint.longitude){ |
| | | this.form.longitude = this.chosePoint.longitude |
| | | this.form.latitude = this.chosePoint.latitude |
| | | this.form.place = this.chosePoint.address |
| | | this.point = "POINT("+this.form.longitude +" "+this.form.latitude+")" |
| | | this.placeBox = false |
| | | }else { |
| | | this.$alert('该点没有位置信息,请重新选点!', '提示', { |
| | | confirmButtonText: '确定', |
| | | }); |
| | | } |
| | | |
| | | } |
| | | } |
| | | } |