Merge pull request #499 from charithag/release-2.0.x-IOTS-342

Fixed https://wso2.org/jira/browse/IOTS-342
4.x.x
Ayyoob Hamza 8 years ago committed by GitHub
commit 4960fd0d05

@ -120,14 +120,14 @@
<h4>
Select user roles to manage group sharing
<br><br>
<div style="max-height: 200px; overflow: scroll" id="rolesListing">
<div style="max-height: 200px; overflow: auto" id="rolesListing">
</div>
</h4>
</div>
</div>
<div class="modal-footer">
<div class="buttons">
{{#if permissions.CREATE_GROUP_ROLES}}
{{#if permissions.ADD_ROLE}}
<a href="{{@app.context}}/role/add" class="btn-operations">
New Role
</a>
@ -186,9 +186,9 @@
<div class="content">
<div class="row">
<div class="col-lg-5 col-md-6 col-centered">
<h3>Group was successfully updated.</h3>
<h3>Group successfully updated.</h3>
<br />
Do you need to Add / Remove users to the chosen roles?
Do you want to manage users?
<div class="buttons">
<a href="{{@app.context}}/users" id="share-group-add-users-yes-link"
class="btn-operations">
@ -211,7 +211,7 @@
<div class="col-lg-5 col-md-6 col-centered">
<h3>New Role was successfully created.</h3>
<br />
Do you need to Add / Remove users to the chosen roles?
Do you need to Add / Remove users from the chosen roles?
<div class="buttons">
<a href="{{@app.context}}/users" id="share-group-add-users-yes-link"
class="btn-operations">

@ -20,13 +20,11 @@ function onRequest(context) {
var groupModule = require("/app/modules/business-controllers/group.js")["groupModule"];
var userModule = require("/app/modules/business-controllers/user.js")["userModule"];
var constants = require("/app/modules/constants.js");
var groupPermissions = require("/app/pages/cdmf.page.groups/public/group-permissions.json");
var currentUser = session.get(constants.USER_SESSION_KEY);
var page = {};
if (currentUser) {
page.permissions = userModule.getUIPermissions();
page.permissions.list = stringify(page.permissions);
page.groupPermissions = groupPermissions.permissionList;
page.currentUser = currentUser;
var groupCount = groupModule.getGroupCount();
if (groupCount > 0) {

@ -1,15 +0,0 @@
{
"permissionList":["device-mgt/admin/groups/view",
"device-mgt/groups/add",
"device-mgt/groups/devices/add",
"device-mgt/groups/devices/remove",
"device-mgt/groups/devices/view",
"device-mgt/groups/remove",
"device-mgt/groups/roles/create",
"device-mgt/groups/roles/view",
"device-mgt/groups/share",
"device-mgt/groups/update",
"device-mgt/groups/users/view",
"device-mgt/groups/view"
]
}

@ -96,7 +96,7 @@ function loadGroups() {
serviceURL = "/api/device-mgt/v1.0/admin/groups";
} else if ($.hasPermission("LIST_GROUPS")) {
//Get authenticated users groups
serviceURL = "/api/device-mgt/v1.0/groups/user/" + currentUser;
serviceURL = "/api/device-mgt/v1.0/groups";
} else {
$("#loading-content").remove();
$('#device-table').addClass('hidden');

Loading…
Cancel
Save