From 05a324404020983f388ee1e41a9bc79ef9b4118e Mon Sep 17 00:00:00 2001 From: manoj Date: Sat, 30 May 2015 02:16:50 +0530 Subject: [PATCH] Add payload to policy operation --- .../device/mgt/core/dto/operation/mgt/PolicyOperation.java | 3 --- .../mgt/core/operation/mgt/dao/util/OperationDAOUtil.java | 5 +++++ .../carbon/policy/mgt/core/PolicyManagerServiceImpl.java | 2 +- 3 files changed, 6 insertions(+), 4 deletions(-) diff --git a/components/device-mgt/org.wso2.carbon.device.mgt.core/src/main/java/org/wso2/carbon/device/mgt/core/dto/operation/mgt/PolicyOperation.java b/components/device-mgt/org.wso2.carbon.device.mgt.core/src/main/java/org/wso2/carbon/device/mgt/core/dto/operation/mgt/PolicyOperation.java index 3c39af660f..f1d97a0dd0 100644 --- a/components/device-mgt/org.wso2.carbon.device.mgt.core/src/main/java/org/wso2/carbon/device/mgt/core/dto/operation/mgt/PolicyOperation.java +++ b/components/device-mgt/org.wso2.carbon.device.mgt.core/src/main/java/org/wso2/carbon/device/mgt/core/dto/operation/mgt/PolicyOperation.java @@ -17,9 +17,6 @@ */ package org.wso2.carbon.device.mgt.core.dto.operation.mgt; -import org.wso2.carbon.device.mgt.core.dto.operation.mgt.Operation; -import org.wso2.carbon.device.mgt.core.dto.operation.mgt.ProfileOperation; - import java.util.List; public class PolicyOperation extends Operation{ diff --git a/components/device-mgt/org.wso2.carbon.device.mgt.core/src/main/java/org/wso2/carbon/device/mgt/core/operation/mgt/dao/util/OperationDAOUtil.java b/components/device-mgt/org.wso2.carbon.device.mgt.core/src/main/java/org/wso2/carbon/device/mgt/core/operation/mgt/dao/util/OperationDAOUtil.java index 7e8641ac57..f09f83a303 100644 --- a/components/device-mgt/org.wso2.carbon.device.mgt.core/src/main/java/org/wso2/carbon/device/mgt/core/operation/mgt/dao/util/OperationDAOUtil.java +++ b/components/device-mgt/org.wso2.carbon.device.mgt.core/src/main/java/org/wso2/carbon/device/mgt/core/operation/mgt/dao/util/OperationDAOUtil.java @@ -19,6 +19,11 @@ package org.wso2.carbon.device.mgt.core.operation.mgt.dao.util; import org.wso2.carbon.device.mgt.core.dto.operation.mgt.*; +import org.wso2.carbon.device.mgt.core.dto.operation.mgt.CommandOperation; +import org.wso2.carbon.device.mgt.core.dto.operation.mgt.ConfigOperation; +import org.wso2.carbon.device.mgt.core.dto.operation.mgt.PolicyOperation; +import org.wso2.carbon.device.mgt.core.dto.operation.mgt.ProfileOperation; +import org.wso2.carbon.device.mgt.core.operation.mgt.*; public class OperationDAOUtil { diff --git a/components/policy-mgt/org.wso2.carbon.policy.mgt.core/src/main/java/org/wso2/carbon/policy/mgt/core/PolicyManagerServiceImpl.java b/components/policy-mgt/org.wso2.carbon.policy.mgt.core/src/main/java/org/wso2/carbon/policy/mgt/core/PolicyManagerServiceImpl.java index 76c5cccb91..907db0b2c1 100644 --- a/components/policy-mgt/org.wso2.carbon.policy.mgt.core/src/main/java/org/wso2/carbon/policy/mgt/core/PolicyManagerServiceImpl.java +++ b/components/policy-mgt/org.wso2.carbon.policy.mgt.core/src/main/java/org/wso2/carbon/policy/mgt/core/PolicyManagerServiceImpl.java @@ -119,7 +119,7 @@ public class PolicyManagerServiceImpl implements PolicyManagerService { policyOperation.setProfileOperations(profileOperationList); PolicyManagementDataHolder.getInstance().getDeviceManagementService(). addOperation(policyOperation, deviceIdentifiers); - + policyOperation.setPayLoad(policyOperation.getProfileOperations()); } else { return null; }