Skip to content

Commit

Permalink
Role - Changes to display of full access label on organizations in roles
Browse files Browse the repository at this point in the history
ui list when a permission granting full access is removed.
  • Loading branch information
ehelms committed Sep 7, 2011
1 parent 6d34e96 commit 43ff99d
Showing 1 changed file with 14 additions and 4 deletions.
18 changes: 14 additions & 4 deletions src/public/javascripts/role_sliding_tree.js
Expand Up @@ -621,10 +621,20 @@ var roleActions = (function($){
cache : false,
dataType : 'json',
success : function(data){
/*if( roles_breadcrumb[id].type === "all" ){
roles_breadcrumb[current_organization].full_access = false
}*/
delete roles_breadcrumb[id];
if( roles_breadcrumb[id].type === "all" ){
delete roles_breadcrumb[id];
roles_breadcrumb[current_organization].full_access = false;

for( item in roles_breadcrumb ){
if( roles_breadcrumb.hasOwnProperty(item) ){
if( item.split('_')[0] === 'permission' && item.split('_')[1] === id.split('_')[1] && roles_breadcrumb[item].type === 'all'){
roles_breadcrumb[current_organization].full_access = true;
}
}
}
} else {
delete roles_breadcrumb[id];
}
roles_breadcrumb[current_organization].count -= 1;
KT.roles.tree.rerender_content();
}
Expand Down

0 comments on commit 43ff99d

Please sign in to comment.