1
0
forked from MTSR/mapserver
mapserver/static/js/overlays/MissionOverlay.js

23 lines
699 B
JavaScript
Raw Normal View History

2019-06-11 16:01:16 +03:00
import AbstractIconOverlay from './AbstractIconOverlay.js';
2019-02-08 17:25:37 +03:00
var MissionIcon = L.icon({
iconUrl: 'pics/mission_32px.png',
iconSize: [32, 32],
iconAnchor: [16, 16],
popupAnchor: [0, -32]
});
2019-06-11 16:01:16 +03:00
export default AbstractIconOverlay.extend({
2019-02-08 17:25:37 +03:00
initialize: function(wsChannel, layerMgr) {
AbstractIconOverlay.prototype.initialize.call(this, wsChannel, layerMgr, "mission", MissionIcon);
},
createPopup: function(mission){
return "<p>Owner: " + mission.attributes.owner + "</p>" +
"<p>Name: " + mission.attributes.name + "</p>" +
"<p>Successcount: " + mission.attributes.successcount + "</p>" +
"<p>Failcount: " + mission.attributes.failcount + "</p>";
}
});