From 31c25de95663c7d25345515ff0e70e5ca3121179 Mon Sep 17 00:00:00 2001 From: Gimhan-minion Date: Thu, 13 Jun 2024 00:51:15 +0530 Subject: [PATCH] Modify permission of operation status update --- .../jaxrs/service/api/DeviceManagementService.java | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/components/device-mgt/io.entgra.device.mgt.core.device.mgt.api/src/main/java/io/entgra/device/mgt/core/device/mgt/api/jaxrs/service/api/DeviceManagementService.java b/components/device-mgt/io.entgra.device.mgt.core.device.mgt.api/src/main/java/io/entgra/device/mgt/core/device/mgt/api/jaxrs/service/api/DeviceManagementService.java index f1e464a0d9..a028654cdc 100644 --- a/components/device-mgt/io.entgra.device.mgt.core.device.mgt.api/src/main/java/io/entgra/device/mgt/core/device/mgt/api/jaxrs/service/api/DeviceManagementService.java +++ b/components/device-mgt/io.entgra.device.mgt.core.device.mgt.api/src/main/java/io/entgra/device/mgt/core/device/mgt/api/jaxrs/service/api/DeviceManagementService.java @@ -165,6 +165,13 @@ import java.util.Map; roles = {"Internal/devicemgt-user"}, permissions = {"/device-mgt/devices/change-status"} ), + @Scope( + name = "Update status of a given operation", + description = "Updates the status of a given operation of a given device", + key = "dm:devices:ops:status:update", + roles = {"Internal/devicemgt-user"}, + permissions = {"/device-mgt/devices/operations/status-update"} + ), @Scope( name = "Enroll Device", description = "Register a device", @@ -2714,12 +2721,12 @@ public interface DeviceManagementService { @ApiOperation( produces = MediaType.APPLICATION_JSON, httpMethod = "PUT", - value = "Update status of a given opeation", + value = "Update status of a given operation", notes = "Updates the status of a given operation of a given device in Entgra IoT Server.", tags = "Device Management", extensions = { @Extension(properties = { - @ExtensionProperty(name = Constants.SCOPE, value = "dm:devices:ops:view") + @ExtensionProperty(name = Constants.SCOPE, value = "dm:devices:ops:status:update") }) } )