mirror of
https://github.com/PepperDash/Essentials.git
synced 2026-04-12 20:17:03 +00:00
fix: remove StringEnumConverter
This commit is contained in:
parent
e03874a7a9
commit
fd1ba345aa
2 changed files with 12 additions and 1 deletions
|
|
@ -14,11 +14,21 @@ namespace PepperDash.Essentials.AppServer.Messengers
|
|||
public class CurrentSourcesMessenger : MessengerBase
|
||||
{
|
||||
private readonly ICurrentSources sourceDevice;
|
||||
|
||||
/// <summary>
|
||||
/// Initializes a new instance of the <see cref="CurrentSourcesMessenger"/> class.
|
||||
/// </summary>
|
||||
/// <param name="key">The key.</param>
|
||||
/// <param name="messagePath">The message path.</param>
|
||||
/// <param name="device">The device.</param>
|
||||
public CurrentSourcesMessenger(string key, string messagePath, ICurrentSources device) : base(key, messagePath, device as IKeyName)
|
||||
{
|
||||
sourceDevice = device;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Registers the actions for the messenger.
|
||||
/// </summary>
|
||||
protected override void RegisterActions()
|
||||
{
|
||||
base.RegisterActions();
|
||||
|
|
@ -55,7 +65,6 @@ namespace PepperDash.Essentials.AppServer.Messengers
|
|||
/// Gets or sets the CurrentSourceKey
|
||||
/// </summary>
|
||||
[JsonProperty("currentSourceKey", NullValueHandling = NullValueHandling.Ignore)]
|
||||
[JsonConverter(typeof(StringEnumConverter))]
|
||||
public Dictionary<eRoutingSignalType, string> CurrentSourceKeys { get; set; }
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -728,6 +728,8 @@ namespace PepperDash.Essentials
|
|||
var messenger = new CurrentSourcesMessenger($"{device.Key}-currentSources-{Key}", $"/device/{device.Key}", currentSources);
|
||||
|
||||
AddDefaultDeviceMessenger(messenger);
|
||||
|
||||
messengerAdded = true;
|
||||
}
|
||||
|
||||
if (device is ISwitchedOutput switchedDevice)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue