From 666733723690b3d8178441927549d102591e25bd Mon Sep 17 00:00:00 2001 From: kisfenyo Date: Fri, 23 Jan 2026 12:12:50 +0100 Subject: [PATCH] updated time format --- glance-system/glance-helper.yaml | 9 +++++++++ glance-system/glance-orsi.yaml | 19 ++++++++++--------- 2 files changed, 19 insertions(+), 9 deletions(-) diff --git a/glance-system/glance-helper.yaml b/glance-system/glance-helper.yaml index b1d7644..74f700e 100644 --- a/glance-system/glance-helper.yaml +++ b/glance-system/glance-helper.yaml @@ -1046,6 +1046,9 @@ data: "calendar": calendar_name, "start": occ.isoformat(), "start_unix": int(occ.timestamp()), + "start_date": occ.strftime("%b %d"), + "start_time": occ.strftime("%H:%M"), + "start_weekday": occ.strftime("%a"), "end": occ_end.isoformat() if occ_end else None, "end_unix": int(occ_end.timestamp()) if occ_end else None, "is_all_day": is_all_day, @@ -1062,6 +1065,9 @@ data: "calendar": calendar_name, "start": dtstart_val.isoformat(), "start_unix": int(dtstart_val.timestamp()), + "start_date": dtstart_val.strftime("%b %d"), + "start_time": dtstart_val.strftime("%H:%M"), + "start_weekday": dtstart_val.strftime("%a"), "end": dtend_val.isoformat() if dtend_val else None, "end_unix": int(dtend_val.timestamp()) if dtend_val else None, "is_all_day": is_all_day, @@ -1077,6 +1083,9 @@ data: "calendar": calendar_name, "start": dtstart_val.isoformat(), "start_unix": int(dtstart_val.timestamp()), + "start_date": dtstart_val.strftime("%b %d"), + "start_time": dtstart_val.strftime("%H:%M"), + "start_weekday": dtstart_val.strftime("%a"), "end": dtend_val.isoformat() if dtend_val else None, "end_unix": int(dtend_val.timestamp()) if dtend_val else None, "is_all_day": is_all_day, diff --git a/glance-system/glance-orsi.yaml b/glance-system/glance-orsi.yaml index 3b1e4e0..8edeefc 100644 --- a/glance-system/glance-orsi.yaml +++ b/glance-system/glance-orsi.yaml @@ -562,7 +562,7 @@ data: widgets: # Calendar Events Widget (Órák & Családi) - type: custom-api - title: Next Events + title: Naptár cache: 5m url: http://glance-helper.glance-system.svc.cluster.local:8000/calendar/events parameters: @@ -637,20 +637,21 @@ data:
- Next events ({{ $count }}) + Következő események ({{ $count }})
{{ if lt $count 1 }} -
No event in near future.
+
Nincs közelgő esemény.
{{ else }} {{ if $hasMore }}{{ end }}
{{ range $i, $e := $events }} {{ $isExtra := ge $i $showCount }} - {{ $start := $e.String "start" }} {{ $isAllDay := $e.Bool "is_all_day" }} {{ $calendar := $e.String "calendar" }} {{ $title := $e.String "title" }} + {{ $startDate := $e.String "start_date" }} + {{ $startTime := $e.String "start_time" }}
@@ -658,19 +659,19 @@ data:
{{ $calendar }}
-
{{ formatTime $start "Jan 2" }}
+
{{ $startDate }}
{{ if $isAllDay }} -
Whole Day
+
Egész nap
{{ else }} -
{{ formatTime $start "15:04" }}
+
{{ $startTime }}
{{ end }}
{{ end }}
{{ if $hasMore }} - - + + {{ end }} {{ end }}