Add HardwareId property to hardware devices in data.json (#1868)
* add HardwareId property to hardware in data.json * Rename 'id' key to 'Id' in JSON node generation --------- Co-authored-by: PhyxionNL <7643972+PhyxionNL@users.noreply.github.com>
This commit is contained in:
@@ -625,7 +625,7 @@ public class HttpServer
|
||||
{
|
||||
JObject jsonNode = new()
|
||||
{
|
||||
["id"] = nodeIndex++,
|
||||
["Id"] = nodeIndex++,
|
||||
["Text"] = n.Text,
|
||||
["Min"] = string.Empty,
|
||||
["Value"] = string.Empty,
|
||||
@@ -643,6 +643,7 @@ public class HttpServer
|
||||
jsonNode["ImageURL"] = "images/transparent.png";
|
||||
break;
|
||||
case HardwareNode hardwareNode:
|
||||
jsonNode["HardwareId"] = hardwareNode.Hardware.Identifier.ToString();
|
||||
jsonNode["ImageURL"] = "images_icon/" + GetHardwareImageFile(hardwareNode);
|
||||
break;
|
||||
case TypeNode typeNode:
|
||||
|
||||
Reference in New Issue
Block a user