mapserver/server/static/js/overlays/TravelnetOverlay.js

33 lines
641 B
JavaScript
Raw Normal View History

2019-02-01 14:58:26 +03:00
'use strict';
2019-01-29 20:08:54 +03:00
2019-02-01 14:58:26 +03:00
var TravelnetIcon = L.icon({
iconUrl: 'pics/travelnet_inv.png',
2019-01-29 20:08:54 +03:00
2019-02-01 14:58:26 +03:00
iconSize: [64, 64],
iconAnchor: [32, 32],
popupAnchor: [0, -32]
});
2019-01-29 20:08:54 +03:00
2019-02-01 14:58:26 +03:00
var TravelnetOverlay = L.LayerGroup.extend({
2019-02-01 15:20:50 +03:00
initialize: function(wsChannel, layerMgr) {
2019-01-29 23:07:29 +03:00
2019-02-01 14:58:26 +03:00
},
2019-01-29 23:07:29 +03:00
2019-02-01 14:58:26 +03:00
onAdd: function(map) {
console.log("TravelnetOverlay.onAdd", map);
2019-01-29 20:08:54 +03:00
2019-02-01 14:58:26 +03:00
map.on('baselayerchange', function (e) {
console.log("baselayerchange", e.layer);
});
2019-01-29 20:08:54 +03:00
2019-02-01 14:58:26 +03:00
api.getMapObjects(-10,-10,-10,10,10,10,"travelnet")
.then(function(list){
console.log(list);
})
},
onRemove: function(map) {
console.log("TravelnetOverlay.onRemove");
}
});