From d24ba9864314d34cd8129317a5b2ead50b40258b Mon Sep 17 00:00:00 2001 From: dilanua Date: Wed, 7 Sep 2016 16:15:26 +0530 Subject: [PATCH] Updating activate and deactivate policy endpoints from PUT to POST --- .../device/mgt/jaxrs/service/api/PolicyManagementService.java | 2 +- .../mgt/jaxrs/service/impl/PolicyManagementServiceImpl.java | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/components/device-mgt/org.wso2.carbon.device.mgt.api/src/main/java/org/wso2/carbon/device/mgt/jaxrs/service/api/PolicyManagementService.java b/components/device-mgt/org.wso2.carbon.device.mgt.api/src/main/java/org/wso2/carbon/device/mgt/jaxrs/service/api/PolicyManagementService.java index 1ede29f3e87..da0931e10fe 100644 --- a/components/device-mgt/org.wso2.carbon.device.mgt.api/src/main/java/org/wso2/carbon/device/mgt/jaxrs/service/api/PolicyManagementService.java +++ b/components/device-mgt/org.wso2.carbon.device.mgt.api/src/main/java/org/wso2/carbon/device/mgt/jaxrs/service/api/PolicyManagementService.java @@ -374,7 +374,7 @@ public interface PolicyManagementService { required = true) List policyIds); - @PUT + @POST @Path("/deactivate-policy") @ApiOperation( consumes = MediaType.APPLICATION_JSON, diff --git a/components/device-mgt/org.wso2.carbon.device.mgt.api/src/main/java/org/wso2/carbon/device/mgt/jaxrs/service/impl/PolicyManagementServiceImpl.java b/components/device-mgt/org.wso2.carbon.device.mgt.api/src/main/java/org/wso2/carbon/device/mgt/jaxrs/service/impl/PolicyManagementServiceImpl.java index 109bb189d42..bb8759e685e 100644 --- a/components/device-mgt/org.wso2.carbon.device.mgt.api/src/main/java/org/wso2/carbon/device/mgt/jaxrs/service/impl/PolicyManagementServiceImpl.java +++ b/components/device-mgt/org.wso2.carbon.device.mgt.api/src/main/java/org/wso2/carbon/device/mgt/jaxrs/service/impl/PolicyManagementServiceImpl.java @@ -254,7 +254,7 @@ public class PolicyManagementServiceImpl implements PolicyManagementService { } } - @PUT + @POST @Path("/activate-policy") @Override public Response activatePolicies(List policyIds) { @@ -286,7 +286,7 @@ public class PolicyManagementServiceImpl implements PolicyManagementService { } } - @PUT + @POST @Path("/deactivate-policy") @Override public Response deactivatePolicies(List policyIds) {