Version:
diff --git a/Lora-Map/resources/js/marker.js b/Lora-Map/resources/js/marker.js
index 28a9fd8..2bd30cc 100644
--- a/Lora-Map/resources/js/marker.js
+++ b/Lora-Map/resources/js/marker.js
@@ -42,7 +42,7 @@ function parseAjaxLoc() {
}
}
updateStatus();
- updateDeviceStatus();
+ update_pannels_info();
}
}
diff --git a/Lora-Map/resources/js/menu.js b/Lora-Map/resources/js/menu.js
index e94b341..0b49c1c 100644
--- a/Lora-Map/resources/js/menu.js
+++ b/Lora-Map/resources/js/menu.js
@@ -4,6 +4,9 @@ function showHidePanel(name) {
document.getElementById("pannels").style.display = "block";
document.getElementById(name).style.display = "block";
visiblePanel = name;
+ if (typeof window["update_" + name] === "function") {
+ window["update_" + name]();
+ }
} else if (visiblePanel === name && name !== "pannels_info" || name === null) {
document.getElementById("pannels").style.display = "none";
if (visiblePanel !== null) {
@@ -14,29 +17,29 @@ function showHidePanel(name) {
document.getElementById(visiblePanel).style.display = "none";
document.getElementById(name).style.display = "block";
visiblePanel = name;
+ if (typeof window["update_" + name] === "function") {
+ window["update_" + name]();
+ }
}
}
var statusToDevice = null;
function showMarkerInfo(e) {
- showHidePanel("pannels_info");
statusToDevice = this;
- updateDeviceStatus();
+ showHidePanel("pannels_info");
}
function showMarkerInfoPerId(id) {
- showHidePanel("pannels_info");
statusToDevice = id;
- updateDeviceStatus();
+ showHidePanel("pannels_info");
}
function showMarkerInfoMenu() {
- showHidePanel("pannels_info");
statusToDevice = this.getAttribute("rel");
- updateDeviceStatus();
+ showHidePanel("pannels_info");
}
-function updateDeviceStatus() {
+function update_pannels_info() {
document.getElementById("pannels_info").innerHTML = "";
if (serverLocation.hasOwnProperty(statusToDevice)) {
var positionItem = serverLocation[statusToDevice];
@@ -110,4 +113,9 @@ function createOverviewElement(positionItem, id) {
divItem.innerHTML += "
kein GPS-Empfang
";
divItem.innerHTML += "
Letzter Datenempfang: vor " + timeCalculation(positionItem["Recievedtime"], "difftext") + "
";
return divItem;
+}
+
+
+function update_pannels_admin() {
+ alert("update admin");
}
\ No newline at end of file