20 lines
485 B
C#
20 lines
485 B
C#
using System.Text.Json.Nodes;
|
|
|
|
namespace InnovEnergy.Lib.StatusApi;
|
|
|
|
public record InstallationStatus : IInstallationStatus
|
|
{
|
|
public IDeviceStack[] Stacks { get; init; }
|
|
|
|
public JsonNode ToJson()
|
|
{
|
|
/* var json = new Dictionary<String, JsonNode>();
|
|
|
|
if (Stacks.Any())
|
|
{
|
|
json[nameof(Stacks)] = new JsonArray(Stacks.Select(d => d.ToJson()).ToArray());
|
|
}
|
|
return new JsonObject(json!);*/
|
|
return null;
|
|
}
|
|
} |