Bugfixing und einige Platzhalterseiten mit Daten gefüllt

This commit is contained in:
2025-10-07 11:19:08 +02:00
parent e7a2f4bb54
commit f969df8cb8
11 changed files with 146 additions and 84 deletions

View File

@@ -46,13 +46,13 @@ class Clock(Page):
return True
return False
def set_location(self, city, country, lat, lon):
def set_location(self, city, country, lat, lon, tz='UTC'):
try:
# Astral ab Debian 13
self.location = astral.LocationInfo((city, country, lat, lon, 'UTC'))
self.location = astral.LocationInfo((city, country, lat, lon, tz))
except AttributeError:
# Astral bis Debian 12 (Version 1.6.1)
self.location = astral.Location((city, country, lat, lon, 'UTC'))
self.location = astral.Location((city, country, lat, lon, tz))
self.location.astral = astral.Astral()
def display_new(self):