This commit is contained in:
charithag 2016-03-28 13:28:49 +05:30
parent 501fefc2d2
commit 062a843ca2
2 changed files with 3 additions and 2 deletions

View File

@ -40,7 +40,7 @@
</a>
</li>
{{else}}
{{#if permissions.addDevice}}
{{#if permissions.enroll}}
<li>
<a href="{{@app.context}}/device/enroll" class="cu-btn">
<span class="icon fw-stack">

View File

@ -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;