diff --git a/apis_core/apis_entities/templates/apis_core/apis_entities/abstractentity_form.html b/apis_core/apis_entities/templates/apis_core/apis_entities/abstractentity_form.html
index fe46449a3..ba1f09dd6 100644
--- a/apis_core/apis_entities/templates/apis_core/apis_entities/abstractentity_form.html
+++ b/apis_core/apis_entities/templates/apis_core/apis_entities/abstractentity_form.html
@@ -172,25 +172,30 @@
};
activate_editing();
-function showmap(element) {
+function showMap(element) {
$('.popover').remove();
- var rect = element.getBoundingClientRect();
- mapdiv = document.createElement("div");
- mapdiv.classList.add("popover");
- mapdiv.setAttribute("id", "popovermap");
- ptop = rect.top + window.scrollY - 250;
- pleft = rect.left + window.scrollX - 550;
- $(mapdiv).offset({top: ptop, left: pleft});
- document.body.appendChild(mapdiv);
+ let rect = element.getBoundingClientRect();
+ let pTop = rect.top + window.scrollY - 250;
+ let pLeft = rect.left + window.scrollX - 550;
+
+ let mapDiv = document.createElement("div");
+ mapDiv.classList.add("popover");
+ mapDiv.setAttribute("id", "popovermap");
+
+ $(mapDiv).offset({top: pTop, left: pLeft});
+ document.body.appendChild(mapDiv);
if (typeof map != "undefined") { map.off(); map.remove(); }
- map = L.map('popovermap', { center: [element.dataset.lat, element.dataset.lng], zoom: 5 });
- L.tileLayer('https://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png', { attribution: '© OpenStreetMap contributors' }).addTo(map);
+
+ let map = L.map('popovermap', { center: [element.dataset.lat, element.dataset.lng], zoom: 5 });
+ L.tileLayer('https://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png', {
+ attribution: '© OpenStreetMap contributors'
+ }).addTo(map);
L.marker([element.dataset.lat, element.dataset.lng]).addTo(map);
-};
+}
-function delmap(element) {
+function delMap(element) {
$('.popover').remove();
}