diff --git a/src/PepperDash.Essentials.MobileControl/WebSocketServer/MobileControlWebsocketServer.cs b/src/PepperDash.Essentials.MobileControl/WebSocketServer/MobileControlWebsocketServer.cs
index a30c0bd2..56e34812 100644
--- a/src/PepperDash.Essentials.MobileControl/WebSocketServer/MobileControlWebsocketServer.cs
+++ b/src/PepperDash.Essentials.MobileControl/WebSocketServer/MobileControlWebsocketServer.cs
@@ -723,7 +723,7 @@ namespace PepperDash.Essentials.WebSocketServer
private UiClient BuildUiClient(string roomKey, JoinToken token, string key)
{
- var c = new UiClient($"uiclient-{key}-{roomKey}-{token.Id}", token.Id, token.Token);
+ var c = new UiClient($"uiclient-{key}-{roomKey}-{token.Id}", token.Id, token.Token, token.TouchpanelKey);
this.LogInformation("Constructing UiClient with key {key} and ID {id}", key, token.Id);
c.Controller = _parent;
c.RoomKey = roomKey;
diff --git a/src/PepperDash.Essentials.MobileControl/WebSocketServer/UiClient.cs b/src/PepperDash.Essentials.MobileControl/WebSocketServer/UiClient.cs
index e4e8a47d..b5299ab7 100644
--- a/src/PepperDash.Essentials.MobileControl/WebSocketServer/UiClient.cs
+++ b/src/PepperDash.Essentials.MobileControl/WebSocketServer/UiClient.cs
@@ -31,6 +31,11 @@ namespace PepperDash.Essentials.WebSocketServer
///
public string Token { get; private set; }
+ ///
+ /// Touchpanel Key associated with this client
+ ///
+ public string TouchpanelKey { get; private set; }
+
///
/// Gets or sets the mobile control system controller that handles this client's messages
///
@@ -75,11 +80,13 @@ namespace PepperDash.Essentials.WebSocketServer
/// The unique key to identify this client
/// The client ID used by the client for this connection
/// The token associated with this client
- public UiClient(string key, string id, string token)
+ /// The touchpanel key associated with this client
+ public UiClient(string key, string id, string token, string touchpanelKey = "")
{
Key = key;
Id = id;
Token = token;
+ TouchpanelKey = touchpanelKey;
}
///
@@ -105,6 +112,7 @@ namespace PepperDash.Essentials.WebSocketServer
{
clientId = Id,
roomKey = RoomKey,
+ touchpanelKey = string.IsNullOrEmpty(TouchpanelKey) ? TouchpanelKey : string.Empty,
})
};