function farm_map_farm_access_perms in farmOS 7
Implements hook_farm_access_perms().
File
- modules/
farm/ farm_map/ farm_map.module, line 41
Code
function farm_map_farm_access_perms($role) {
$perms = array();
// Load the list of farm roles.
$roles = farm_access_roles();
// If this role has 'config' access,grant access to map configuration.
if (!empty($roles[$role]['access']['config'])) {
$perms[] = 'administer farm_map module';
}
return $perms;
}