[MRM-1764] #users > edit roles -- please sort repository list for ease of use

git-svn-id: https://svn.apache.org/repos/asf/archiva/redback/redback-core/trunk@1546261 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Olivier Lamy 2013-11-28 03:03:52 +00:00
parent ddc1d53a74
commit 2a538f9d58
1 changed files with 9 additions and 1 deletions

View File

@ -631,7 +631,11 @@ public class DefaultRoleManagementService
Collection<org.apache.archiva.redback.rbac.Role> appRoles =
filterApplicationRoles( modelApplication, allRoles, modelApplication.getTemplates() );
applicationRoles.setGlobalRoles( toRoleNames( appRoles ) );
List<String> roleNames = new ArrayList<String>( toRoleNames( appRoles ) );
Collections.sort( roleNames );
applicationRoles.setGlobalRoles( roleNames );
Set<String> resources = discoverResources( modelApplication.getTemplates(), appRoles );
@ -651,8 +655,12 @@ public class DefaultRoleManagementService
}
}
Collections.sort( appRoleNames );
applicationRoles.setGlobalRoles( appRoleNames );
Collections.sort( appRoleNames );
applicationRolesList.add( applicationRoles );
}