From d2d341963d490541790fe4133b9db65d9c09c866 Mon Sep 17 00:00:00 2001 From: "osh.silva" Date: Wed, 24 Jul 2024 13:05:41 +0530 Subject: [PATCH] Fix search issues --- .../application/mgt/common/SubscriptionMetadata.java | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/components/application-mgt/io.entgra.device.mgt.core.application.mgt.common/src/main/java/io/entgra/device/mgt/core/application/mgt/common/SubscriptionMetadata.java b/components/application-mgt/io.entgra.device.mgt.core.application.mgt.common/src/main/java/io/entgra/device/mgt/core/application/mgt/common/SubscriptionMetadata.java index 8c149bf872..bd487dfea4 100644 --- a/components/application-mgt/io.entgra.device.mgt.core.application.mgt.common/src/main/java/io/entgra/device/mgt/core/application/mgt/common/SubscriptionMetadata.java +++ b/components/application-mgt/io.entgra.device.mgt.core.application.mgt.common/src/main/java/io/entgra/device/mgt/core/application/mgt/common/SubscriptionMetadata.java @@ -35,7 +35,7 @@ public class SubscriptionMetadata { public static final String INVALID = "INVALID"; public static final String UNAUTHORIZED = "UNAUTHORIZED"; public static final String IN_PROGRESS = "IN_PROGRESS"; - public static final String REPEAT = "REPEAT"; + public static final String REPEATED = "REPEATED"; } public static final class SubscriptionTypes { @@ -51,7 +51,7 @@ public class SubscriptionMetadata { public static final List ERROR_STATUS_LIST = Arrays.asList(DeviceSubscriptionStatus.ERROR, DeviceSubscriptionStatus.INVALID, DeviceSubscriptionStatus.UNAUTHORIZED); public static final List PENDING_STATUS_LIST = - Arrays.asList(DeviceSubscriptionStatus.PENDING, DeviceSubscriptionStatus.IN_PROGRESS, DeviceSubscriptionStatus.REPEAT); + Arrays.asList(DeviceSubscriptionStatus.PENDING, DeviceSubscriptionStatus.IN_PROGRESS, DeviceSubscriptionStatus.REPEATED); } public static Map> deviceSubscriptionStatusToDBSubscriptionStatusMap; @@ -59,11 +59,11 @@ public class SubscriptionMetadata { Map> statusMap = new HashMap<>(); statusMap.put(DeviceSubscriptionStatus.COMPLETED, DBSubscriptionStatus.COMPLETED_STATUS_LIST); statusMap.put(DeviceSubscriptionStatus.PENDING, DBSubscriptionStatus.PENDING_STATUS_LIST); - statusMap.put(DeviceSubscriptionStatus.IN_PROGRESS, DBSubscriptionStatus.PENDING_STATUS_LIST); - statusMap.put(DeviceSubscriptionStatus.REPEAT, DBSubscriptionStatus.PENDING_STATUS_LIST); + statusMap.put(DeviceSubscriptionStatus.IN_PROGRESS, Collections.singletonList(DeviceSubscriptionStatus.IN_PROGRESS)); + statusMap.put(DeviceSubscriptionStatus.REPEATED, Collections.singletonList(DeviceSubscriptionStatus.REPEATED)); statusMap.put(DeviceSubscriptionStatus.ERROR, DBSubscriptionStatus.ERROR_STATUS_LIST); - statusMap.put(DeviceSubscriptionStatus.INVALID, DBSubscriptionStatus.ERROR_STATUS_LIST); - statusMap.put(DeviceSubscriptionStatus.UNAUTHORIZED, DBSubscriptionStatus.ERROR_STATUS_LIST); + statusMap.put(DeviceSubscriptionStatus.INVALID,Collections.singletonList(DeviceSubscriptionStatus.INVALID)); + statusMap.put(DeviceSubscriptionStatus.UNAUTHORIZED,Collections.singletonList(DeviceSubscriptionStatus.UNAUTHORIZED)); deviceSubscriptionStatusToDBSubscriptionStatusMap = Collections.unmodifiableMap(statusMap); } } -- 2.36.3