Commit 591804e9 by fengfan

map

parent 6d7360c2
......@@ -159,9 +159,9 @@
map: map
});
}
AMapUI.loadUI(['geo/DistrictExplorer'], function (DistrictExplorer) {
initMask(DistrictExplorer);
});
// AMapUI.loadUI(['geo/DistrictExplorer'], function (DistrictExplorer) {
// initMask(DistrictExplorer);
// });
// 获取人员信息
$.getJSON('./personal.json').then(res => {
console.log(JSON.parse(res));
......
......@@ -109,7 +109,7 @@
mask.push([bounds[i]])
}
map = new AMap.Map('container', {
mask: mask,
// mask: mask,
center: [
result.districtList[0].center.lng,
result.districtList[0].center.lat
......@@ -124,10 +124,10 @@
// layers: [RoadNet,Satellite ]//Satellite,
// layers: [road, ]//Satellite,
});
map.add(Satellite);
map.add(CanvasLayer);
map.add(SatelliteDown);
map.getLayers()[0].setzIndex(1000)
map.add(Satellite);//高亮mask 卫星图
map.add(CanvasLayer);// 半黑遮罩层
map.add(SatelliteDown);//底图 卫星图
map.getLayers()[0].setzIndex(1000);//个性地图置顶
findsubarea(result);
// map.getLayers()[0].setOpacity(0.5)
// var maskerIn = new AMap.Marker({
......@@ -159,9 +159,9 @@
map: map
});
}
AMapUI.loadUI(['geo/DistrictExplorer'], function (DistrictExplorer) {
initMask(DistrictExplorer);
});
// AMapUI.loadUI(['geo/DistrictExplorer'], function (DistrictExplorer) {
// initMask(DistrictExplorer);
// });
// 获取人员信息
$.getJSON('./personal.json').then(res => {
console.log(JSON.parse(res));
......@@ -278,21 +278,23 @@
// }
// }
// ],
zooms: [14, 20],
center: new AMap.LngLat(Number(item.lon), Number(item.lat)),
// zooms: [1, 20],
// center: new AMap.LngLat(Number(item.lon), Number(item.lat)),
position: new AMap.LngLat(Number(item.lon), Number(item.lat)),
zIndex: 1000,
zoomStyleMapping: {
14: 0,
15: 0,
16: 0,
17: 0,
18: 0,
19: 0,
20: 0
}
// zIndex: 1000,
// zoomStyleMapping: {
// 14: 0,
// 15: 0,
// 16: 0,
// 17: 0,
// 18: 0,
// 19: 0,
// 20: 0
// }
});
map.add(marker);
console.log(marker);
// map.add(marker);
}
console.log(AMap.ElasticMarker);
</script>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment