From d9f226eb28431bdb3374aef7ecdb6d7bcc2a898d Mon Sep 17 00:00:00 2001 From: salim ben ahben <40862545+Sben65@users.noreply.github.com> Date: Fri, 4 Feb 2022 16:39:51 +0100 Subject: [PATCH] condition on createEnrollmentGroup fix (#193) --- .../Server/Controllers/GatewaysController.cs | 4 ++-- .../Server/Managers/DeviceProvisioningServiceManager.cs | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/AzureIoTHub.Portal/Server/Controllers/GatewaysController.cs b/src/AzureIoTHub.Portal/Server/Controllers/GatewaysController.cs index 780f3941c..2b9552614 100644 --- a/src/AzureIoTHub.Portal/Server/Controllers/GatewaysController.cs +++ b/src/AzureIoTHub.Portal/Server/Controllers/GatewaysController.cs @@ -58,9 +58,9 @@ public async Task Get() { try { - // ne contient pas les proprieter + // don't contain properties IEnumerable devicesWithoutProperties = await this.devicesService.GetAllEdgeDeviceWithTags(); - // ne contien pas les appareil connecter + // don't contain connected device IEnumerable edgeDevices = await this.devicesService.GetAllEdgeDevice(); List newGatewayList = new (); diff --git a/src/AzureIoTHub.Portal/Server/Managers/DeviceProvisioningServiceManager.cs b/src/AzureIoTHub.Portal/Server/Managers/DeviceProvisioningServiceManager.cs index 15b8c9e0b..6de795058 100644 --- a/src/AzureIoTHub.Portal/Server/Managers/DeviceProvisioningServiceManager.cs +++ b/src/AzureIoTHub.Portal/Server/Managers/DeviceProvisioningServiceManager.cs @@ -28,7 +28,7 @@ public async Task CreateEnrollmentGroupAsync(string deviceType) TwinCollection tags; TwinCollection desiredProperties; - if (deviceType == "LoRa") + if (deviceType == "LoRa Device") { enrollmentGroupId = this.config.DPSLoRaEnrollmentGroup; tags = new TwinCollection("{ \"purpose\":\"" + "LoRaNetworkServer" + "\" }"); @@ -67,7 +67,7 @@ public async Task CreateEnrollmentGroupAsync(string deviceType) /// AttestationMechanism. public async Task GetAttestationMechanism(string deviceType) { - if (deviceType == "LoRa") + if (deviceType == "LoRa Device") { return await this.dps.GetEnrollmentGroupAttestationAsync(this.config.DPSLoRaEnrollmentGroup); }