fix: Geräte-Marker für Systeme ohne Statusdaten anzeigen (z. B. GMA)

- `createAndSetDevices.js` angepasst, sodass Marker auch ohne `statusDistrictData` erzeugt werden.
- Problem behoben, dass Marker wie GMA trotz vorhandener Koordinaten und Sichtbarkeit nicht gezeichnet wurden.
- Sicherheitsprüfung für Statusdaten optional gemacht, um Systems ohne Messdaten darzustellen.
This commit is contained in:
ISA
2025-07-30 11:13:34 +02:00
parent 6d33be56c0
commit 53c670feba
15 changed files with 87 additions and 41 deletions

View File

@@ -70,7 +70,8 @@ const useDynamicDeviceLayers = (map, GisSystemStatic, mapLayersVisibility, prior
const editMode = localStorage.getItem("editMode") === "true";
Object.entries(markerStates).forEach(([key, markers]) => {
const isVisible = mapLayersVisibility[key];
const isVisible = mapLayersVisibility[key] ?? true; // undefined = true
markers.forEach(marker => {
const hasLayer = map.hasLayer(marker);
if (editMode || !isVisible) {