From eb9d4a5d7d55d2ad37750af8a2b1cd747f31baab Mon Sep 17 00:00:00 2001
From: salim ben ahben <40862545+Sben65@users.noreply.github.com>
Date: Tue, 1 Feb 2022 12:17:02 +0100
Subject: [PATCH] fix #154 (#155)
---
.../Client/Pages/Devices/CreateDevicePage.razor | 2 +-
.../Client/Pages/Devices/DeviceDetailPage.razor | 2 +-
src/AzureIoTHub.Portal/Server/Mappers/DeviceTwinMapper.cs | 4 ++--
src/AzureIoTHub.Portal/Shared/Models/Device/DeviceDetails.cs | 2 +-
4 files changed, 5 insertions(+), 5 deletions(-)
diff --git a/src/AzureIoTHub.Portal/Client/Pages/Devices/CreateDevicePage.razor b/src/AzureIoTHub.Portal/Client/Pages/Devices/CreateDevicePage.razor
index 728cdb801..75236d5c3 100644
--- a/src/AzureIoTHub.Portal/Client/Pages/Devices/CreateDevicePage.razor
+++ b/src/AzureIoTHub.Portal/Client/Pages/Devices/CreateDevicePage.razor
@@ -56,7 +56,7 @@
CoerceText="true" CoerceValue="false" />
-
+
diff --git a/src/AzureIoTHub.Portal/Client/Pages/Devices/DeviceDetailPage.razor b/src/AzureIoTHub.Portal/Client/Pages/Devices/DeviceDetailPage.razor
index e94763fc6..707964103 100644
--- a/src/AzureIoTHub.Portal/Client/Pages/Devices/DeviceDetailPage.razor
+++ b/src/AzureIoTHub.Portal/Client/Pages/Devices/DeviceDetailPage.razor
@@ -58,7 +58,7 @@
-
+
diff --git a/src/AzureIoTHub.Portal/Server/Mappers/DeviceTwinMapper.cs b/src/AzureIoTHub.Portal/Server/Mappers/DeviceTwinMapper.cs
index 29562aeb1..708fcb277 100644
--- a/src/AzureIoTHub.Portal/Server/Mappers/DeviceTwinMapper.cs
+++ b/src/AzureIoTHub.Portal/Server/Mappers/DeviceTwinMapper.cs
@@ -41,7 +41,7 @@ public DeviceDetails CreateDeviceDetails(Twin twin)
AppEUI = Helpers.DeviceHelper.RetrieveDesiredPropertyValue(twin, nameof(DeviceDetails.AppEUI)),
AppKey = Helpers.DeviceHelper.RetrieveDesiredPropertyValue(twin, nameof(DeviceDetails.AppKey)),
LocationCode = Helpers.DeviceHelper.RetrieveTagValue(twin, nameof(DeviceDetails.LocationCode)),
- AssetID = Helpers.DeviceHelper.RetrieveTagValue(twin, nameof(DeviceDetails.AssetID)),
+ AssetId = Helpers.DeviceHelper.RetrieveTagValue(twin, nameof(DeviceDetails.AssetId)),
SensorDecoder = Helpers.DeviceHelper.RetrieveDesiredPropertyValue(twin, nameof(DeviceDetails.SensorDecoder)),
DeviceType = Helpers.DeviceHelper.RetrieveTagValue(twin, nameof(DeviceDetails.DeviceType)),
Commands = this.deviceModelCommandsManager.RetrieveCommands(modelId)
@@ -65,7 +65,7 @@ public void UpdateTwin(Twin twin, DeviceDetails item)
{
// Update the twin properties
Helpers.DeviceHelper.SetTagValue(twin, nameof(item.LocationCode), item.LocationCode);
- Helpers.DeviceHelper.SetTagValue(twin, nameof(item.AssetID), item.AssetID);
+ Helpers.DeviceHelper.SetTagValue(twin, nameof(item.AssetId), item.AssetId);
Helpers.DeviceHelper.SetTagValue(twin, nameof(item.LocationCode), item.LocationCode);
Helpers.DeviceHelper.SetTagValue(twin, nameof(item.DeviceType), item.DeviceType);
Helpers.DeviceHelper.SetTagValue(twin, nameof(item.ModelId), item.ModelId);
diff --git a/src/AzureIoTHub.Portal/Shared/Models/Device/DeviceDetails.cs b/src/AzureIoTHub.Portal/Shared/Models/Device/DeviceDetails.cs
index be3c43613..89307b913 100644
--- a/src/AzureIoTHub.Portal/Shared/Models/Device/DeviceDetails.cs
+++ b/src/AzureIoTHub.Portal/Shared/Models/Device/DeviceDetails.cs
@@ -28,7 +28,7 @@ public class DeviceDetails
public string LocationCode { get; set; }
- public string AssetID { get; set; }
+ public string AssetId { get; set; }
public string DeviceType { get; set; }