Add a global capability for viewing all accounts
Users with this capability can auto-complete all accounts regardless of the global accounts.visibility setting. The use case is a core group of committers that should be able to view all accounts, where the rest of the contributors are all in small, non-overlapping accounts that should not be able to view one another. For small numbers of groups it is sufficient to add the committer groups to each of the contributor groups, but this approach becomes a maintenance headache as the number of contributor groups grows to the 10-100 range. Change-Id: Ib31d642484459afa0c129524bc0bc52348dd7416
This commit is contained in:
committed by
Edwin Kempin
parent
d4d01dcc1b
commit
f3548a9e90
@@ -110,6 +110,12 @@ public class CapabilityControl {
|
||||
|| canAdministrateServer();
|
||||
}
|
||||
|
||||
/** @return true if the user can view all accounts. */
|
||||
public boolean canViewAllAccounts() {
|
||||
return canPerform(GlobalCapability.VIEW_ALL_ACCOUNTS)
|
||||
|| canAdministrateServer();
|
||||
}
|
||||
|
||||
/** @return true if the user can view the server caches. */
|
||||
public boolean canViewCaches() {
|
||||
return canPerform(GlobalCapability.VIEW_CACHES)
|
||||
|
||||
Reference in New Issue
Block a user