From a3255a0ced3c16d9fbd0b8a6269a7a309e1c2836 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jesko=20Ansch=C3=BCtz?= Date: Thu, 26 Mar 2026 23:23:50 +0100 Subject: [PATCH] feat(agent): display_state im Status-Report --- player/agent/internal/statusreporter/reporter.go | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/player/agent/internal/statusreporter/reporter.go b/player/agent/internal/statusreporter/reporter.go index f06b0d8..2c247ce 100644 --- a/player/agent/internal/statusreporter/reporter.go +++ b/player/agent/internal/statusreporter/reporter.go @@ -19,6 +19,7 @@ type Snapshot struct { HeartbeatEverySeconds int StartedAt time.Time LastHeartbeatAt time.Time + DisplayState string } type statusPayload struct { @@ -31,6 +32,7 @@ type statusPayload struct { HeartbeatEverySeconds int `json:"heartbeat_every_seconds"` StartedAt string `json:"started_at,omitempty"` LastHeartbeatAt string `json:"last_heartbeat_at,omitempty"` + DisplayState string `json:"display_state,omitempty"` } // MQTTConfig holds the MQTT broker configuration returned by the server in the @@ -138,5 +140,9 @@ func buildPayload(snapshot Snapshot, now time.Time) statusPayload { payload.LastHeartbeatAt = snapshot.LastHeartbeatAt.Format(time.RFC3339) } + if snapshot.DisplayState != "" { + payload.DisplayState = snapshot.DisplayState + } + return payload }