public static function UcAddressesPermissions::canViewAll in Ubercart Addresses 7
Same name and namespace in other branches
- 6.2 class/UcAddressesPermissions.class.php \UcAddressesPermissions::canViewAll()
If the account may view all addresses.
@access public @static
Parameters
object $account: (optional) The account to check access for. Defaults to the current active user.
Return value
boolean TRUE if the account may view all addresses. FALSE otherwise.
4 calls to UcAddressesPermissions::canViewAll()
- UcAddressesPermissions::canViewAddress in class/
UcAddressesPermissions.class.php - Check if user may view this address.
- UcAddressesPermissions::canViewAllDefaults in class/
UcAddressesPermissions.class.php - If the account may view all default addresses.
- UcAddressesPermissions::canViewOwn in class/
UcAddressesPermissions.class.php - If the account may view its own addresses.
- uc_addresses_entity_access in ./
uc_addresses.module - Access callback for address entity.
File
- class/
UcAddressesPermissions.class.php, line 312 - Permission class.
Class
- UcAddressesPermissions
- The permission class: UcAddressesPermissions.
Code
public static function canViewAll($account = NULL) {
$account = self::getAccount($account);
return user_access(self::VIEW_ALL, $account) || self::canEditAll($account) || self::canDeleteAll($account);
}