From 80a08a274418201ae223fcc1a88fac80a6f3ba16 Mon Sep 17 00:00:00 2001 From: Menaka Jayawardena Date: Tue, 29 Aug 2017 15:17:02 +0530 Subject: [PATCH] Redirect to Group Listing page after creating a Group. --- .../app/pages/cdmf.page.group.create/create.hbs | 13 +------------ .../cdmf.page.group.create/public/js/group-add.js | 3 +++ 2 files changed, 4 insertions(+), 12 deletions(-) diff --git a/components/device-mgt/org.wso2.carbon.device.mgt.ui/src/main/resources/jaggeryapps/devicemgt/app/pages/cdmf.page.group.create/create.hbs b/components/device-mgt/org.wso2.carbon.device.mgt.ui/src/main/resources/jaggeryapps/devicemgt/app/pages/cdmf.page.group.create/create.hbs index 9e6ee54a711..62cea7955e9 100644 --- a/components/device-mgt/org.wso2.carbon.device.mgt.ui/src/main/resources/jaggeryapps/devicemgt/app/pages/cdmf.page.group.create/create.hbs +++ b/components/device-mgt/org.wso2.carbon.device.mgt.ui/src/main/resources/jaggeryapps/devicemgt/app/pages/cdmf.page.group.create/create.hbs @@ -73,18 +73,7 @@

Group was created successfully.

-
Please click "Add Another Group", if you wish to add another group or click - "View Group List" to complete the process and go back to the group list. -
- - - - - - - Add Another Group - +
You will be redirected to the Group Listing page in a moment.
diff --git a/components/device-mgt/org.wso2.carbon.device.mgt.ui/src/main/resources/jaggeryapps/devicemgt/app/pages/cdmf.page.group.create/public/js/group-add.js b/components/device-mgt/org.wso2.carbon.device.mgt.ui/src/main/resources/jaggeryapps/devicemgt/app/pages/cdmf.page.group.create/public/js/group-add.js index 85b34decd95..59c27b321bc 100644 --- a/components/device-mgt/org.wso2.carbon.device.mgt.ui/src/main/resources/jaggeryapps/devicemgt/app/pages/cdmf.page.group.create/public/js/group-add.js +++ b/components/device-mgt/org.wso2.carbon.device.mgt.ui/src/main/resources/jaggeryapps/devicemgt/app/pages/cdmf.page.group.create/public/js/group-add.js @@ -47,6 +47,9 @@ $(function () { if (resp.status == 201) { $("#group-create-form").addClass("hidden"); $("#group-created-msg").removeClass("hidden"); + setTimeout(function(){ + window.location.href = "/devicemgt/groups"; + }, 1000); } else { displayErrors(resp.status); }