From 062a843ca2ceff551678ac70139d6d85b171ad32 Mon Sep 17 00:00:00 2001 From: charithag Date: Mon, 28 Mar 2016 13:28:49 +0530 Subject: [PATCH] Fix for https://wso2.org/jira/browse/IOTS-99 --- .../devicemgt/app/pages/cdmf.page.devices/devices.hbs | 2 +- .../devicemgt/app/pages/cdmf.page.devices/devices.js | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/components/device-mgt/org.wso2.carbon.device.mgt.ui/src/main/resources/jaggeryapps/devicemgt/app/pages/cdmf.page.devices/devices.hbs b/components/device-mgt/org.wso2.carbon.device.mgt.ui/src/main/resources/jaggeryapps/devicemgt/app/pages/cdmf.page.devices/devices.hbs index 7770787a6ce..f17d24d014f 100644 --- a/components/device-mgt/org.wso2.carbon.device.mgt.ui/src/main/resources/jaggeryapps/devicemgt/app/pages/cdmf.page.devices/devices.hbs +++ b/components/device-mgt/org.wso2.carbon.device.mgt.ui/src/main/resources/jaggeryapps/devicemgt/app/pages/cdmf.page.devices/devices.hbs @@ -40,7 +40,7 @@ {{else}} - {{#if permissions.addDevice}} + {{#if permissions.enroll}}
  • diff --git a/components/device-mgt/org.wso2.carbon.device.mgt.ui/src/main/resources/jaggeryapps/devicemgt/app/pages/cdmf.page.devices/devices.js b/components/device-mgt/org.wso2.carbon.device.mgt.ui/src/main/resources/jaggeryapps/devicemgt/app/pages/cdmf.page.devices/devices.js index 78de1083943..50480ab8280 100644 --- a/components/device-mgt/org.wso2.carbon.device.mgt.ui/src/main/resources/jaggeryapps/devicemgt/app/pages/cdmf.page.devices/devices.js +++ b/components/device-mgt/org.wso2.carbon.device.mgt.ui/src/main/resources/jaggeryapps/devicemgt/app/pages/cdmf.page.devices/devices.js @@ -26,10 +26,11 @@ function onRequest(context) { page.groupName = groupName; } page.title =title; + page.permissions = {}; var currentUser = session.get(constants.USER_SESSION_KEY); if (currentUser) { if (userModule.isAuthorized("/permission/admin/device-mgt/admin/devices/add")) { - page.addDevice = true; + page.permissions.enroll = true; } } return page;