You are here

public function OrgPermissions::OrgTypePermissions in RedHen CRM 8

Returns an array of RedHen org type permissions.

Return value

array Returns an array of permissions.

1 string reference to 'OrgPermissions::OrgTypePermissions'
redhen_org.permissions.yml in modules/redhen_org/redhen_org.permissions.yml
modules/redhen_org/redhen_org.permissions.yml

File

modules/redhen_org/src/OrgPermissions.php, line 18

Class

OrgPermissions

Namespace

Drupal\redhen_org

Code

public function OrgTypePermissions() {
  $perms = [];

  // Generate org permissions for all org types.
  foreach (OrgType::loadMultiple() as $type) {
    $perms += $this
      ->buildPermissions($type);
  }
  return $perms;
}