From cff69a4588875f9a173e858c5d10e9ba75f384cb Mon Sep 17 00:00:00 2001 From: Pasindu Date: Tue, 23 May 2017 09:25:42 +0530 Subject: [PATCH 1/7] Remove enter --- .../src/main/resources/build.properties | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/features/policy-mgt/org.wso2.carbon.policy.mgt.server.feature/src/main/resources/build.properties b/features/policy-mgt/org.wso2.carbon.policy.mgt.server.feature/src/main/resources/build.properties index 9c86577d768..19b7d5d5c6f 100644 --- a/features/policy-mgt/org.wso2.carbon.policy.mgt.server.feature/src/main/resources/build.properties +++ b/features/policy-mgt/org.wso2.carbon.policy.mgt.server.feature/src/main/resources/build.properties @@ -1 +1 @@ -custom = true + custom = true \ No newline at end of file From a855dfcf86fe170fdf28bf8222a1f0c290be2409 Mon Sep 17 00:00:00 2001 From: Pasindu Date: Fri, 23 Jun 2017 12:18:12 +0530 Subject: [PATCH 2/7] Remove unwanted changes --- .../src/main/resources/build.properties | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/features/policy-mgt/org.wso2.carbon.policy.mgt.server.feature/src/main/resources/build.properties b/features/policy-mgt/org.wso2.carbon.policy.mgt.server.feature/src/main/resources/build.properties index 19b7d5d5c6f..93c4b10701e 100644 --- a/features/policy-mgt/org.wso2.carbon.policy.mgt.server.feature/src/main/resources/build.properties +++ b/features/policy-mgt/org.wso2.carbon.policy.mgt.server.feature/src/main/resources/build.properties @@ -1 +1 @@ - custom = true \ No newline at end of file +custom = true \ No newline at end of file From 1581775aa636da8c99033a843fa78a812b78228e Mon Sep 17 00:00:00 2001 From: Pasindu Date: Fri, 1 Sep 2017 15:38:28 +0530 Subject: [PATCH 3/7] Fixes validation issue in create group --- .../mgt/jaxrs/service/impl/GroupManagementServiceImpl.java | 2 +- .../jaggeryapps/devicemgt/app/pages/cdmf.page.users/users.js | 2 -- 2 files changed, 1 insertion(+), 3 deletions(-) diff --git a/components/device-mgt/org.wso2.carbon.device.mgt.api/src/main/java/org/wso2/carbon/device/mgt/jaxrs/service/impl/GroupManagementServiceImpl.java b/components/device-mgt/org.wso2.carbon.device.mgt.api/src/main/java/org/wso2/carbon/device/mgt/jaxrs/service/impl/GroupManagementServiceImpl.java index 8bab08463b3..6d09cbcad6b 100644 --- a/components/device-mgt/org.wso2.carbon.device.mgt.api/src/main/java/org/wso2/carbon/device/mgt/jaxrs/service/impl/GroupManagementServiceImpl.java +++ b/components/device-mgt/org.wso2.carbon.device.mgt.api/src/main/java/org/wso2/carbon/device/mgt/jaxrs/service/impl/GroupManagementServiceImpl.java @@ -109,7 +109,7 @@ public class GroupManagementServiceImpl implements GroupManagementService { log.error(msg, e); return Response.status(Response.Status.INTERNAL_SERVER_ERROR).entity(msg).build(); } catch (GroupAlreadyExistException e) { - String msg = "Group already exists with name '" + group.getName() + "'."; + String msg = "Group already exists with name \'" + group.getName() + "\'."; log.warn(msg); return Response.status(Response.Status.CONFLICT).entity(msg).build(); } diff --git a/components/device-mgt/org.wso2.carbon.device.mgt.ui/src/main/resources/jaggeryapps/devicemgt/app/pages/cdmf.page.users/users.js b/components/device-mgt/org.wso2.carbon.device.mgt.ui/src/main/resources/jaggeryapps/devicemgt/app/pages/cdmf.page.users/users.js index 4b7f9c01bc6..d75a753c1fb 100644 --- a/components/device-mgt/org.wso2.carbon.device.mgt.ui/src/main/resources/jaggeryapps/devicemgt/app/pages/cdmf.page.users/users.js +++ b/components/device-mgt/org.wso2.carbon.device.mgt.ui/src/main/resources/jaggeryapps/devicemgt/app/pages/cdmf.page.users/users.js @@ -42,7 +42,5 @@ function onRequest(context) { if (userModule.isAuthorized("/permission/admin/device-mgt/users/view")) { page.canView = true; } - - return page; } \ No newline at end of file From f8f82e66db8c1ba6ea7574c67f06ba8deb7da1e2 Mon Sep 17 00:00:00 2001 From: Pasindu Date: Fri, 1 Sep 2017 15:51:57 +0530 Subject: [PATCH 4/7] Fix validate error display issue --- .../main/resources/jaggeryapps/devicemgt/app/conf/config.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/components/device-mgt/org.wso2.carbon.device.mgt.ui/src/main/resources/jaggeryapps/devicemgt/app/conf/config.json b/components/device-mgt/org.wso2.carbon.device.mgt.ui/src/main/resources/jaggeryapps/devicemgt/app/conf/config.json index c807fa7e9e3..63d8b2d504d 100644 --- a/components/device-mgt/org.wso2.carbon.device.mgt.ui/src/main/resources/jaggeryapps/devicemgt/app/conf/config.json +++ b/components/device-mgt/org.wso2.carbon.device.mgt.ui/src/main/resources/jaggeryapps/devicemgt/app/conf/config.json @@ -46,7 +46,7 @@ }, "groupValidationConfig": { "groupNameJSRegEx": "^[\\S]{3,30}$", - "groupNameRegExViolationErrorMsg": "Provided group name is invalid.", + "groupNameRegExViolationErrorMsg": "Group name should be in minimum 3 characters long and should not include any whitespaces.", "groupNameHelpMsg": "Should be in minimum 3 characters long and should not include any whitespaces." }, "roleValidationConfig": { From 2363da7767ff061fd9b1e6d89ce3072abc35b0e4 Mon Sep 17 00:00:00 2001 From: Pasindu Date: Fri, 1 Sep 2017 16:02:58 +0530 Subject: [PATCH 5/7] Formatting issue --- .../src/main/resources/build.properties | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/features/policy-mgt/org.wso2.carbon.policy.mgt.server.feature/src/main/resources/build.properties b/features/policy-mgt/org.wso2.carbon.policy.mgt.server.feature/src/main/resources/build.properties index 93c4b10701e..9c86577d768 100644 --- a/features/policy-mgt/org.wso2.carbon.policy.mgt.server.feature/src/main/resources/build.properties +++ b/features/policy-mgt/org.wso2.carbon.policy.mgt.server.feature/src/main/resources/build.properties @@ -1 +1 @@ -custom = true \ No newline at end of file +custom = true From 8000124f8c6e9b9e30fe31b6676f35b56a041fc1 Mon Sep 17 00:00:00 2001 From: Pasindu Date: Fri, 1 Sep 2017 16:48:30 +0530 Subject: [PATCH 6/7] Fixes validation of role when creating new user --- .../app/pages/cdmf.page.user.create/public/js/bottomJs.js | 3 +++ 1 file changed, 3 insertions(+) diff --git a/components/device-mgt/org.wso2.carbon.device.mgt.ui/src/main/resources/jaggeryapps/devicemgt/app/pages/cdmf.page.user.create/public/js/bottomJs.js b/components/device-mgt/org.wso2.carbon.device.mgt.ui/src/main/resources/jaggeryapps/devicemgt/app/pages/cdmf.page.user.create/public/js/bottomJs.js index 28d4af3fdb2..83a581368ee 100644 --- a/components/device-mgt/org.wso2.carbon.device.mgt.ui/src/main/resources/jaggeryapps/devicemgt/app/pages/cdmf.page.user.create/public/js/bottomJs.js +++ b/components/device-mgt/org.wso2.carbon.device.mgt.ui/src/main/resources/jaggeryapps/devicemgt/app/pages/cdmf.page.user.create/public/js/bottomJs.js @@ -256,6 +256,9 @@ $(document).ready(function () { } else if (!emailIsValid(emailAddress)) { $(errorMsg).text("Provided email is invalid."); $(errorMsgWrapper).removeClass("hidden"); + } else if (!roles) { + $(errorMsg).text("Role is a required field. It cannot be empty."); + $(errorMsgWrapper).removeClass("hidden"); } else { var addUserFormData = {}; From 54b69747cefd7600f373ad6886e86335edb16bb6 Mon Sep 17 00:00:00 2001 From: Pasindu Date: Fri, 1 Sep 2017 17:57:11 +0530 Subject: [PATCH 7/7] Fixes issue in modal displaying group name --- .../mgt/jaxrs/service/impl/GroupManagementServiceImpl.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/components/device-mgt/org.wso2.carbon.device.mgt.api/src/main/java/org/wso2/carbon/device/mgt/jaxrs/service/impl/GroupManagementServiceImpl.java b/components/device-mgt/org.wso2.carbon.device.mgt.api/src/main/java/org/wso2/carbon/device/mgt/jaxrs/service/impl/GroupManagementServiceImpl.java index 1db00919f8e..d1e816a430d 100644 --- a/components/device-mgt/org.wso2.carbon.device.mgt.api/src/main/java/org/wso2/carbon/device/mgt/jaxrs/service/impl/GroupManagementServiceImpl.java +++ b/components/device-mgt/org.wso2.carbon.device.mgt.api/src/main/java/org/wso2/carbon/device/mgt/jaxrs/service/impl/GroupManagementServiceImpl.java @@ -110,7 +110,7 @@ public class GroupManagementServiceImpl implements GroupManagementService { log.error(msg, e); return Response.status(Response.Status.INTERNAL_SERVER_ERROR).entity(msg).build(); } catch (GroupAlreadyExistException e) { - String msg = "Group already exists with name \'" + group.getName() + "\'."; + String msg = "Group already exists with name " + group.getName() + "."; log.warn(msg); return Response.status(Response.Status.CONFLICT).entity(msg).build(); }