Keine Bearbeitungszusammenfassung |
Keine Bearbeitungszusammenfassung |
||
| (4 dazwischenliegende Versionen von 2 Benutzern werden nicht angezeigt) | |||
| Zeile 2: | Zeile 2: | ||
__NOTOC__ | __NOTOC__ | ||
{{#widget:ClubStatus}} | {{#widget:ClubStatus}} | ||
</noinclude> | </noinclude><includeonly><script> | ||
<includeonly> | |||
<script> | |||
(() => { | (() => { | ||
const OPENED_CLASS = 'widget-clubstatus__type--opened'; | const OPENED_CLASS = 'widget-clubstatus__type--opened'; | ||
| Zeile 26: | Zeile 20: | ||
} | } | ||
const lastChangeDateTimeString = (new Date(lastChange).toLocaleString('de-DE')); | const lastChangeDateTimeString = (new Date(lastChange * 1000).toLocaleString('de-DE')); | ||
clubStatusMarker.setAttribute('title', 'letzte Änderung: ' + lastChangeDateTimeString); | clubStatusMarker.setAttribute('title', 'letzte Änderung: ' + lastChangeDateTimeString); | ||
| Zeile 34: | Zeile 28: | ||
fetch('/api/entropia-club-status-json-api.php') | fetch('/api/entropia-club-status-json-api.php') | ||
.then(response => response.json()) | .then(response => response.json()) | ||
.then(data => setClubStatus(data[" | .then(data => setClubStatus(data["state"]["open"], data["state"]["lastchange"])); | ||
} | } | ||
| Zeile 41: | Zeile 35: | ||
updateClubStatus(); | updateClubStatus(); | ||
})(); | })(); | ||
</script> | </script></includeonly> | ||
</includeonly | |||
Aktuelle Version vom 4. Januar 2026, 21:05 Uhr