From d95ea63dd8a816ab912796cb215dce6fb3898a2a Mon Sep 17 00:00:00 2001 From: Kevin Kandlbinder Date: Mon, 5 Sep 2022 19:58:23 +0200 Subject: [PATCH] webui: Add debug switch to Room Details --- webui/src/components/panel/rooms/RoomDetail.tsx | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/webui/src/components/panel/rooms/RoomDetail.tsx b/webui/src/components/panel/rooms/RoomDetail.tsx index 65c88c1..e162258 100644 --- a/webui/src/components/panel/rooms/RoomDetail.tsx +++ b/webui/src/components/panel/rooms/RoomDetail.tsx @@ -61,7 +61,18 @@ const RoomDetailInner = ({initialQueryRef}: PropsFinal) => { } } }) - }} disabled={reconfiguringRoom || ((data.room || false) && !data.room.active && !data.room.deactivated)} checked={data.room?.active}/> + }} disabled={reconfiguringRoom || ((data.room || false) && !data.room.active && !data.room.deactivated)} checked={data.room?.active}/>
+ + { + reconfigureRoom({ + variables: { + reconfigureInput: { + id: data.room?.id!, + debug: ev.currentTarget.checked + } + } + }) + }} disabled={reconfiguringRoom || (!data.room)} checked={data.room?.debug}/>
{JSON.stringify(data, null, 2)}