diff --git a/src/PepperDash.Essentials.Core/Comm and IR/CommFactory.cs b/src/PepperDash.Essentials.Core/Comm and IR/CommFactory.cs index f54f4bfd..26b29d51 100644 --- a/src/PepperDash.Essentials.Core/Comm and IR/CommFactory.cs +++ b/src/PepperDash.Essentials.Core/Comm and IR/CommFactory.cs @@ -201,23 +201,26 @@ namespace PepperDash.Essentials.Core /// /// /// - public class EssentialsControlPropertiesConfig : - PepperDash.Core.ControlPropertiesConfig + public class EssentialsControlPropertiesConfig : + ControlPropertiesConfig { + [JsonProperty("comParams")] [JsonConverter(typeof(ComSpecJsonConverter))] - public ComPort.ComPortSpec ComParams { get; set; } + public ComPort.ComPortSpec ComParams { get; set; } - public string CresnetId { get; set; } + [JsonProperty("cresnetId")] + public string CresnetId { get; set; } /// /// Attempts to provide uint conversion of string CresnetId /// + [JsonIgnore] public uint CresnetIdInt { get { - try + try { return Convert.ToUInt32(CresnetId, 16); } @@ -228,11 +231,13 @@ namespace PepperDash.Essentials.Core } } + [JsonProperty("infinetId")] public string InfinetId { get; set; } /// /// Attepmts to provide uiont conversion of string InifinetId /// + [JsonIgnore] public uint InfinetIdInt { get diff --git a/src/PepperDash.Essentials.Core/Touchpanels/CrestronTouchpanelPropertiesConfig.cs b/src/PepperDash.Essentials.Core/Touchpanels/CrestronTouchpanelPropertiesConfig.cs index 5a42bcd1..9b6639db 100644 --- a/src/PepperDash.Essentials.Core/Touchpanels/CrestronTouchpanelPropertiesConfig.cs +++ b/src/PepperDash.Essentials.Core/Touchpanels/CrestronTouchpanelPropertiesConfig.cs @@ -4,46 +4,49 @@ namespace PepperDash.Essentials.Core { public class CrestronTouchpanelPropertiesConfig { - [JsonProperty("ipId")] + [JsonProperty("control")] + public EssentialsControlPropertiesConfig ControlProperties { get; set; } + + [JsonProperty("ipId", NullValueHandling = NullValueHandling.Ignore)] public string IpId { get; set; } - [JsonProperty("defaultRoomKey")] + [JsonProperty("defaultRoomKey", NullValueHandling = NullValueHandling.Ignore)] public string DefaultRoomKey { get; set; } - [JsonProperty("roomListKey")] + [JsonProperty("roomListKey", NullValueHandling = NullValueHandling.Ignore)] public string RoomListKey { get; set; } - [JsonProperty("sgdFile")] + [JsonProperty("sgdFile", NullValueHandling = NullValueHandling.Ignore)] public string SgdFile { get; set; } - [JsonProperty("projectName")] + [JsonProperty("projectName", NullValueHandling = NullValueHandling.Ignore)] public string ProjectName { get; set; } - [JsonProperty("showVolumeGauge")] + [JsonProperty("showVolumeGauge", NullValueHandling = NullValueHandling.Ignore)] public bool ShowVolumeGauge { get; set; } - [JsonProperty("usesSplashPage")] + [JsonProperty("usesSplashPage", NullValueHandling = NullValueHandling.Ignore)] public bool UsesSplashPage { get; set; } - [JsonProperty("showDate")] + [JsonProperty("showDate", NullValueHandling = NullValueHandling.Ignore)] public bool ShowDate { get; set; } - [JsonProperty("showTime")] + [JsonProperty("showTime", NullValueHandling = NullValueHandling.Ignore)] public bool ShowTime { get; set; } - [JsonProperty("setup")] + [JsonProperty("setup", NullValueHandling = NullValueHandling.Ignore)] public UiSetupPropertiesConfig Setup { get; set; } - [JsonProperty("headerStyle")] + [JsonProperty("headerStyle", NullValueHandling = NullValueHandling.Ignore)] public string HeaderStyle { get; set; } - [JsonProperty("includeInFusionRoomHealth")] + [JsonProperty("includeInFusionRoomHealth", NullValueHandling = NullValueHandling.Ignore)] public bool IncludeInFusionRoomHealth { get; set; } - [JsonProperty("screenSaverTimeoutMin")] + [JsonProperty("screenSaverTimeoutMin", NullValueHandling = NullValueHandling.Ignore)] public uint ScreenSaverTimeoutMin { get; set; } - [JsonProperty("screenSaverMovePositionIntervalMs")] + [JsonProperty("screenSaverMovePositionIntervalMs", NullValueHandling = NullValueHandling.Ignore)] public uint ScreenSaverMovePositionIntervalMs { get; set; } @@ -51,7 +54,7 @@ namespace PepperDash.Essentials.Core /// The count of sources that will trigger the "additional" arrows to show on the SRL. /// Defaults to 5 /// - [JsonProperty("sourcesOverflowCount")] + [JsonProperty("sourcesOverflowCount", NullValueHandling = NullValueHandling.Ignore)] public int SourcesOverflowCount { get; set; } public CrestronTouchpanelPropertiesConfig() @@ -79,7 +82,7 @@ namespace PepperDash.Essentials.Core /// public class UiSetupPropertiesConfig { - [JsonProperty("isVisible")] + [JsonProperty("isVisible", NullValueHandling = NullValueHandling.Ignore)] public bool IsVisible { get; set; } } } \ No newline at end of file