From a04300b3b6acbcd980b8e34f222a557e28eae6ff Mon Sep 17 00:00:00 2001 From: geethkokila Date: Thu, 2 Jun 2016 23:09:55 +0530 Subject: [PATCH] Fixing the activity Id issue --- .../core/operation/mgt/dao/impl/GenericOperationDAOImpl.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/components/device-mgt/org.wso2.carbon.device.mgt.core/src/main/java/org/wso2/carbon/device/mgt/core/operation/mgt/dao/impl/GenericOperationDAOImpl.java b/components/device-mgt/org.wso2.carbon.device.mgt.core/src/main/java/org/wso2/carbon/device/mgt/core/operation/mgt/dao/impl/GenericOperationDAOImpl.java index 2fa5f92b481..c6343156ee6 100644 --- a/components/device-mgt/org.wso2.carbon.device.mgt.core/src/main/java/org/wso2/carbon/device/mgt/core/operation/mgt/dao/impl/GenericOperationDAOImpl.java +++ b/components/device-mgt/org.wso2.carbon.device.mgt.core/src/main/java/org/wso2/carbon/device/mgt/core/operation/mgt/dao/impl/GenericOperationDAOImpl.java @@ -283,8 +283,8 @@ public class GenericOperationDAOImpl implements OperationDAO { ActivityStatus activityStatus = null; while (rs.next()) { - activity = new Activity(); if (enrolmentId == 0) { + activity = new Activity(); activity.setType(Activity.Type.valueOf(rs.getString("OPERATION_TYPE"))); activity.setCreatedTimeStamp(new java.util.Date(rs.getLong(("CREATED_TIMESTAMP"))).toString()); activity.setCode(rs.getString("OPERATION_CODE"));