|
|
@@ -1228,7 +1228,7 @@ |
|
|
|
import {listSuyqr,updateSuyqr,addSuyqr} from "@/api/homesteadSurvey/suyqr"; |
|
|
|
import {listZrz,getZrzZjdDmList,getZrz} from "@/api/homesteadSurvey/zrz"; |
|
|
|
import {listFsss,getFsssZjdDmList,getFsss} from "@/api/homesteadSurvey/fsss"; |
|
|
|
import {getGeoServerConfigKey} from "@/api/system/config"; |
|
|
|
import {getGeoServerConfigKey,getConfigKey} from "@/api/system/config"; |
|
|
|
import { listTown, getTown } from "@/api/homesteadSurvey/town"; |
|
|
|
import { listVillage} from "@/api/homesteadSurvey/village"; |
|
|
|
import {deptGetId,} from "@/api/homestead/index"; |
|
|
@@ -1287,6 +1287,11 @@ |
|
|
|
showhncylist:false, |
|
|
|
showhncy:false, |
|
|
|
activeBtn:4, |
|
|
|
mapGeoServerUrl:"", |
|
|
|
mobileSurveykey:'', |
|
|
|
mobileSurveyZrzkey:"", |
|
|
|
mobileSurveyFssskey:"", |
|
|
|
mobileSurveyCjqykey:"", |
|
|
|
value:'', |
|
|
|
// 宅基地搜索框 |
|
|
|
zjdvalue:"", |
|
|
@@ -3018,6 +3023,18 @@ |
|
|
|
// }); |
|
|
|
// } |
|
|
|
// }); |
|
|
|
getConfigKey("geoserver.layer.homestead.mobileSurvey").then(response => { |
|
|
|
this.mobileSurveykey = response.msg; |
|
|
|
}); |
|
|
|
getConfigKey("geoserver.layer.building").then(response => { |
|
|
|
this.mobileSurveyZrzkey = response.msg; |
|
|
|
}); |
|
|
|
getConfigKey("geoserver.layer.annex").then(response => { |
|
|
|
this.mobileSurveyFssskey = response.msg; |
|
|
|
}); |
|
|
|
getConfigKey("geoserver.layer.villageBorder").then(response => { |
|
|
|
this.mobileSurveyCjqykey = response.msg; |
|
|
|
}); |
|
|
|
//通过数据直接查询方式--------加载较慢 end |
|
|
|
getGeoServerConfigKey().then(response => { |
|
|
|
this.mapGeoServerUrl = response.msg; |
|
|
@@ -3025,6 +3042,7 @@ |
|
|
|
this.GetMapsInit(); |
|
|
|
}, 300); |
|
|
|
}); |
|
|
|
|
|
|
|
var that = this; |
|
|
|
setTimeout(function () { |
|
|
|
var height = $(".searchBar_wrap").outerHeight(true) - $(".searchBar_wrap .van-search").outerHeight(true) |
|
|
@@ -3109,7 +3127,7 @@ |
|
|
|
source: new ol.source.ImageWMS({ |
|
|
|
url: that.mapGeoServerUrl + "/wms", |
|
|
|
params: { |
|
|
|
LAYERS: 'nsgk_wulanhaote:t_homespace_cjqy', |
|
|
|
LAYERS: that.mobileSurveyCjqykey, |
|
|
|
TILED: true, |
|
|
|
cql_filter: cql_filter, |
|
|
|
SRID: 3857, |
|
|
@@ -3285,22 +3303,22 @@ |
|
|
|
//村边界查询开始 ------------------------------end |
|
|
|
//国有数据加载-----------------------------------start |
|
|
|
|
|
|
|
deptGetId(that.surveyItem.deptId).then((res) => { |
|
|
|
var cql_filter_guoyou = "ZLDWDM='" + res.data.orgCode + "0000000'"; |
|
|
|
var guoyouTc = new ol.layer.Image({ |
|
|
|
source: new ol.source.ImageWMS({ |
|
|
|
url: that.mapGeoServerUrl + "/geoserver/zjd_gydl/wms", |
|
|
|
params: { |
|
|
|
LAYERS: 'zjd_gydl:DLTB', |
|
|
|
TILED: true, |
|
|
|
cql_filter: cql_filter_guoyou, |
|
|
|
SRID: 3857, |
|
|
|
TIMESTAMP: new Date().getTime(), |
|
|
|
}, |
|
|
|
}), |
|
|
|
}); |
|
|
|
map.addLayer(guoyouTc); |
|
|
|
}); |
|
|
|
// deptGetId(that.surveyItem.deptId).then((res) => { |
|
|
|
// var cql_filter_guoyou = "ZLDWDM='" + res.data.orgCode + "0000000'"; |
|
|
|
// var guoyouTc = new ol.layer.Image({ |
|
|
|
// source: new ol.source.ImageWMS({ |
|
|
|
// url: that.mapGeoServerUrl + "/wms", |
|
|
|
// params: { |
|
|
|
// LAYERS: 'zjd_gydl:DLTB', |
|
|
|
// TILED: true, |
|
|
|
// cql_filter: cql_filter_guoyou, |
|
|
|
// SRID: 3857, |
|
|
|
// TIMESTAMP: new Date().getTime(), |
|
|
|
// }, |
|
|
|
// }), |
|
|
|
// }); |
|
|
|
// map.addLayer(guoyouTc); |
|
|
|
// }); |
|
|
|
//国有数据加载----------------------------------end |
|
|
|
//宅基地图层查询开始 ------------------start |
|
|
|
//var cql_filter_all = "dept_id='" + that.$cookies.get("item").deptId + "'"; |
|
|
@@ -3308,7 +3326,7 @@ |
|
|
|
source: new ol.source.ImageWMS({ |
|
|
|
url: that.mapGeoServerUrl + "/wms", |
|
|
|
params: { |
|
|
|
LAYERS: 'nsgk_wulanhaote:t_homestead_zjdzdxx_mobile_survey', |
|
|
|
LAYERS: that.mobileSurveykey, |
|
|
|
TILED: true, |
|
|
|
cql_filter: cql_filter+" and survey_status = '1'", |
|
|
|
SRID: 3857, |
|
|
@@ -3320,7 +3338,7 @@ |
|
|
|
source: new ol.source.ImageWMS({ |
|
|
|
url: that.mapGeoServerUrl + "/wms", |
|
|
|
params: { |
|
|
|
LAYERS: 'nsgk_wulanhaote:t_homestead_zjdzdxx_mobile_survey', |
|
|
|
LAYERS: that.mobileSurveykey, |
|
|
|
TILED: true, |
|
|
|
cql_filter: cql_filter+" and survey_status = '2'", |
|
|
|
SRID: 3857, |
|
|
@@ -3332,7 +3350,7 @@ |
|
|
|
source: new ol.source.ImageWMS({ |
|
|
|
url: that.mapGeoServerUrl + "/wms", |
|
|
|
params: { |
|
|
|
LAYERS: 'nsgk_wulanhaote:t_homestead_zjdzdxx_mobile_survey', |
|
|
|
LAYERS: that.mobileSurveykey, |
|
|
|
TILED: true, |
|
|
|
cql_filter: cql_filter+" and survey_status = '3'", |
|
|
|
SRID: 3857, |
|
|
@@ -3344,7 +3362,7 @@ |
|
|
|
source: new ol.source.ImageWMS({ |
|
|
|
url: that.mapGeoServerUrl + "/wms", |
|
|
|
params: { |
|
|
|
LAYERS: 'nsgk_wulanhaote:t_homestead_zjdzdxx_mobile_survey', |
|
|
|
LAYERS: that.mobileSurveykey, |
|
|
|
TILED: true, |
|
|
|
cql_filter: cql_filter+" and survey_status = '4'", |
|
|
|
SRID: 3857, |
|
|
@@ -3356,7 +3374,7 @@ |
|
|
|
source: new ol.source.ImageWMS({ |
|
|
|
url: that.mapGeoServerUrl + "/wms", |
|
|
|
params: { |
|
|
|
LAYERS: 'nsgk_wulanhaote:t_homestead_zjdzdxx_mobile_survey', |
|
|
|
LAYERS: that.mobileSurveykey, |
|
|
|
TILED: true, |
|
|
|
cql_filter: cql_filter+" and survey_status = '5'", |
|
|
|
SRID: 3857, |
|
|
@@ -3370,7 +3388,7 @@ |
|
|
|
service: "WFS", |
|
|
|
version: "1.0.0", |
|
|
|
request: "GetFeature", |
|
|
|
typename: "nsgk_wulanhaote:t_homestead_zjdzdxx_mobile_survey", |
|
|
|
typename:that.mobileSurveykey, |
|
|
|
//featureNS: 'nsgk_hc',//命名空间 URI |
|
|
|
cql_filter: cql_filter, |
|
|
|
//featurePrefix: 'nationalwater',//工作区名称 |
|
|
@@ -3400,7 +3418,7 @@ |
|
|
|
source: new ol.source.ImageWMS({ |
|
|
|
url: that.mapGeoServerUrl + "/wms", |
|
|
|
params: { |
|
|
|
LAYERS: 'nsgk_wulanhaote:t_homespace_zrz', |
|
|
|
LAYERS: that.mobileSurveyZrzkey, |
|
|
|
TILED: true, |
|
|
|
cql_filter: cql_filter_map, |
|
|
|
SRID: 3857, |
|
|
@@ -3416,7 +3434,7 @@ |
|
|
|
source: new ol.source.ImageWMS({ |
|
|
|
url: that.mapGeoServerUrl + "/wms", |
|
|
|
params: { |
|
|
|
LAYERS: 'nsgk_wulanhaote:t_homestead_fsss', |
|
|
|
LAYERS: that.mobileSurveyFssskey, |
|
|
|
TILED: true, |
|
|
|
cql_filter: cql_filter_map, |
|
|
|
SRID: 3857, |
|
|
@@ -3533,7 +3551,7 @@ |
|
|
|
source: new ol.source.ImageWMS({ |
|
|
|
url: that.mapGeoServerUrl + "/wms", |
|
|
|
params: { |
|
|
|
LAYERS: 'nsgk_wulanhaote:t_homespace_zrz', |
|
|
|
LAYERS: that.mobileSurveyZrzkey, |
|
|
|
TILED: true, |
|
|
|
cql_filter: cql_filter, |
|
|
|
SRID: 3857, |
|
|
@@ -3549,7 +3567,7 @@ |
|
|
|
source: new ol.source.ImageWMS({ |
|
|
|
url: that.mapGeoServerUrl + "/wms", |
|
|
|
params: { |
|
|
|
LAYERS: 'nsgk_wulanhaote:t_homestead_fsss', |
|
|
|
LAYERS: that.mobileSurveyFssskey, |
|
|
|
TILED: true, |
|
|
|
cql_filter: cql_filter, |
|
|
|
SRID: 3857, |
|
|
@@ -4602,7 +4620,7 @@ |
|
|
|
service: "WFS", |
|
|
|
version: "1.0.0", |
|
|
|
request: "GetFeature", |
|
|
|
typename: "nsgk_wulanhaote:t_homespace_cjqy", |
|
|
|
typename: that.mobileSurveyCjqykey, |
|
|
|
//featureNS: 'nsgk_hc',//命名空间 URI |
|
|
|
cql_filter: cql_filter, |
|
|
|
//featurePrefix: 'nationalwater',//工作区名称 |
|
|
@@ -4624,10 +4642,11 @@ |
|
|
|
return geojsonmap; |
|
|
|
}) |
|
|
|
.then((data) => { |
|
|
|
let resolution = map.getView().getResolutionForExtent(data.bbox,map.getSize()); |
|
|
|
resolution:resolution + Math.random() * 0.00000001, |
|
|
|
map.getView().fit(data.bbox); |
|
|
|
map.getView().setResolution(resolution); |
|
|
|
let resolution = map.getView().getResolutionForExtent(data.bbox,map.getSize()); |
|
|
|
resolution:resolution + Math.random() * 0.00000001, |
|
|
|
map.getView().fit(data.bbox); |
|
|
|
map.getView().setResolution(resolution); |
|
|
|
|
|
|
|
// var datamap = data.bbox; |
|
|
|
// var center = ol.extent.getCenter(datamap); |
|
|
|
// map.getView().animate({ |
|
|
@@ -4655,7 +4674,7 @@ |
|
|
|
var wmsSource = new ol.source.TileWMS({ |
|
|
|
url: that.mapGeoServerUrl+"/wms", |
|
|
|
params: { |
|
|
|
LAYERS: "nsgk_wulanhaote:t_homestead_zjdzdxx_mobile_survey", |
|
|
|
LAYERS:that.mobileSurveykey, |
|
|
|
TILED: true, |
|
|
|
SRID: 3857, |
|
|
|
serverType: "geoserver", |
|
|
@@ -4668,7 +4687,7 @@ |
|
|
|
var ZjdwmsSource = new ol.source.TileWMS({ |
|
|
|
url: that.mapGeoServerUrl+"/wms", |
|
|
|
params: { |
|
|
|
LAYERS: "nsgk_wulanhaote:t_homestead_zjdzdxx_mobile_survey", |
|
|
|
LAYERS: that.mobileSurveykey, |
|
|
|
TILED: true, |
|
|
|
SRID: 3857, |
|
|
|
serverType: "geoserver", |
|
|
@@ -4681,7 +4700,7 @@ |
|
|
|
var ZrzwmsSource = new ol.source.TileWMS({ |
|
|
|
url: that.mapGeoServerUrl+"/wms", |
|
|
|
params: { |
|
|
|
LAYERS: "nsgk_wulanhaote:t_homespace_zrz", |
|
|
|
LAYERS: that.mobileSurveyZrzkey, |
|
|
|
TILED: true, |
|
|
|
SRID: 3857, |
|
|
|
serverType: "geoserver", |
|
|
@@ -4694,7 +4713,7 @@ |
|
|
|
var FssswmsSource = new ol.source.TileWMS({ |
|
|
|
url: that.mapGeoServerUrl+"/wms", |
|
|
|
params: { |
|
|
|
LAYERS: "nsgk_wulanhaote:t_homestead_fsss", |
|
|
|
LAYERS: that.mobileSurveyFssskey, |
|
|
|
TILED: true, |
|
|
|
SRID: 3857, |
|
|
|
serverType: "geoserver", |
|
|
@@ -4879,7 +4898,7 @@ |
|
|
|
source: new ol.source.ImageWMS({ |
|
|
|
url: that.mapGeoServerUrl + "/wms", |
|
|
|
params: { |
|
|
|
LAYERS: 'nsgk_wulanhaote:t_homespace_zrz', |
|
|
|
LAYERS: that.mobileSurveyZrzkey, |
|
|
|
TILED: true, |
|
|
|
cql_filter: cql_filter_map, |
|
|
|
SRID: 3857, |
|
|
@@ -5068,7 +5087,7 @@ |
|
|
|
source: new ol.source.ImageWMS({ |
|
|
|
url: that.mapGeoServerUrl + "/wms", |
|
|
|
params: { |
|
|
|
LAYERS: 'nsgk_wulanhaote:t_homespace_zrz', |
|
|
|
LAYERS: that.mobileSurveyZrzkey, |
|
|
|
TILED: true, |
|
|
|
cql_filter: cql_filter_map, |
|
|
|
SRID: 3857, |
|
|
@@ -5084,7 +5103,7 @@ |
|
|
|
source: new ol.source.ImageWMS({ |
|
|
|
url: that.mapGeoServerUrl + "/wms", |
|
|
|
params: { |
|
|
|
LAYERS: 'nsgk_wulanhaote:t_homestead_fsss', |
|
|
|
LAYERS: that.mobileSurveyFssskey, |
|
|
|
TILED: true, |
|
|
|
cql_filter: cql_filter_map, |
|
|
|
SRID: 3857, |
|
|
@@ -5255,7 +5274,7 @@ |
|
|
|
source: new ol.source.ImageWMS({ |
|
|
|
url: that.mapGeoServerUrl + "/wms", |
|
|
|
params: { |
|
|
|
LAYERS: 'nsgk_wulanhaote:t_homespace_zrz', |
|
|
|
LAYERS: that.mobileSurveyZrzkey, |
|
|
|
TILED: true, |
|
|
|
cql_filter: cql_filter_map, |
|
|
|
SRID: 3857, |
|
|
@@ -5271,7 +5290,7 @@ |
|
|
|
source: new ol.source.ImageWMS({ |
|
|
|
url: that.mapGeoServerUrl + "/wms", |
|
|
|
params: { |
|
|
|
LAYERS: 'nsgk_wulanhaote:t_homestead_fsss', |
|
|
|
LAYERS: that.mobileSurveyFssskey, |
|
|
|
TILED: true, |
|
|
|
cql_filter: cql_filter_map, |
|
|
|
SRID: 3857, |
|
|
|