优化首页
This commit is contained in:
parent
9c98c171ec
commit
8df09f29a3
BIN
sec-beidou/src/main/resources/static/images/loc1_green.png
Normal file
BIN
sec-beidou/src/main/resources/static/images/loc1_green.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 578 B |
BIN
sec-beidou/src/main/resources/static/images/loc_blue.png
Normal file
BIN
sec-beidou/src/main/resources/static/images/loc_blue.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 232 B |
BIN
sec-beidou/src/main/resources/static/images/loc_green.png
Normal file
BIN
sec-beidou/src/main/resources/static/images/loc_green.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 938 B |
BIN
sec-beidou/src/main/resources/static/images/loc_red.png
Normal file
BIN
sec-beidou/src/main/resources/static/images/loc_red.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 231 B |
@ -82,6 +82,7 @@
|
||||
var point = new BMapGL.Point(116.404, 39.915);
|
||||
map.centerAndZoom(point, 7);
|
||||
map.enableScrollWheelZoom(true);
|
||||
//map.setMapType(BMAP_SATELLITE_MAP);
|
||||
var centerLat = 0;
|
||||
var centerLon = 0;
|
||||
var deviceList=
|
||||
@ -92,6 +93,8 @@
|
||||
longitude:[[${device.longitude}]]},
|
||||
[/]
|
||||
];
|
||||
var loc_green = new BMapGL.Icon("../images/loc1_green.png", new BMapGL.Size(18, 24));
|
||||
|
||||
//console.log(deviceList);
|
||||
for(var i=0; i<deviceList.length; i++) {
|
||||
centerLat += deviceList[i].latitude;
|
||||
@ -103,11 +106,14 @@
|
||||
map.setCenter(new BMapGL.Point(centerLon,centerLat));
|
||||
}
|
||||
|
||||
|
||||
translateCallback = function (data){
|
||||
if(data.status === 0) {
|
||||
var i=0;
|
||||
for(; i<data.points.length; i++) {
|
||||
map.addOverlay(new BMapGL.Marker(data.points[i]));
|
||||
map.addOverlay(new BMapGL.Marker(data.points[i],{
|
||||
icon:loc_green
|
||||
}));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user