You are here

function express_permissions_secure_permissions in Express 7.2

Define site permissions in code.

Create a secure_permissions_data module directory and place this function in secure_permissions_data.module.

Parameters

$role: The role for which the permissions are being requested.

Return value

An array defining all the permissions for the site.

File

modules/custom/express_permissions/express_permissions.module, line 66
Defines roles and permissions for the Express profile. Also used to alter some existing core and contrib permissions.

Code

function express_permissions_secure_permissions($role) {
  $permissions = array(
    'administrator' => array(
      'access administration pages',
      'access bean overview',
      'access ckeditor link',
      'access content',
      'access content overview',
      'access contextual links',
      'access user profiles',
      'access users overview',
      'access_google_appliance_content',
      'administer beans',
      'administer blocks',
      'administer checked out documents',
      'administer contexts',
      'administer express settings',
      'administer express theme picker',
      'administer menu',
      'administer nodes',
      'administer people settings',
      'administer redirects',
      'assign content_editor role',
      'assign edit_my_content role',
      'assign site_owner role',
      'cancel users with role authenticated user',
      'cancel users with role content_editor',
      'cancel users with role edit_my_content',
      'cancel users with role site_owner',
      'check out documents',
      'create any block bean',
      'create any feature_callout bean',
      'create any hero_unit bean',
      'create any slider bean',
      'create faqs content',
      'create file content',
      'create page content',
      'create url aliases',
      'customize shortcut links',
      'delete any block bean',
      'delete any faqs content',
      'delete any file content',
      'delete any hero_unit bean',
      'delete any page content',
      'delete any slider bean',
      'delete own faqs content',
      'delete own file content',
      'delete own page content',
      'delete revisions',
      'edit any block bean',
      'edit any faqs content',
      'edit any file content',
      'edit any hero_unit bean',
      'edit any page content',
      'edit any slider bean',
      'edit cu blocks',
      'edit own faqs content',
      'edit own file content',
      'edit own page content',
      'edit users with role authenticated user',
      'edit users with role content_editor',
      'edit users with role edit_my_content',
      'edit users with role site_owner',
      'execute node_assign_owner_action',
      'execute node_make_sticky_action',
      'execute node_make_unsticky_action',
      'execute node_promote_action',
      'execute node_publish_action',
      'execute node_unpromote_action',
      'execute node_unpublish_action',
      'execute node_unpublish_by_keyword_action',
      'execute views_bulk_operations_delete_item',
      'invite new user',
      'preview focal point',
      'revert revisions',
      'use bigmenu',
      'use text format wysiwyg',
      'view any block bean',
      'view any hero_unit bean',
      'view any slider bean',
      'view any unpublished content',
      'view bean page',
      'view bean revisions',
      'view own unpublished content',
      'view revisions',
      'view the administration theme',
      'access navbar',
      'enable module bundles',
      'view status messages',
      'view warning messages',
      'view error messages',
      'administer cache settings',
    ),
    'anonymous user' => array(
      'access content',
      'access_google_appliance_content',
      'view any block bean',
      'view any feature_callout bean',
      'view any hero_unit bean',
      'view any quicktab bean',
      'view any slider bean',
      'view status messages',
      'view warning messages',
      'view error messages',
    ),
    'authenticated user' => array(
      'access content',
      'access_google_appliance_content',
      'delete own webform submissions',
      'skip CAPTCHA',
      'view any block bean',
      'view any feature_callout bean',
      'view any hero_unit bean',
      'view any quicktab bean',
      'view any slider bean',
      'view status messages',
      'view warning messages',
      'view error messages',
    ),
    'content_editor' => array(
      'access administration pages',
      'access bean overview',
      'access ckeditor link',
      'access content overview',
      'access contextual links',
      'access user profiles',
      'administer beans',
      'administer contexts',
      'administer menu',
      'administer nodes',
      'check out documents',
      'create any block bean',
      'create any feature_callout bean',
      'create any hero_unit bean',
      'create any slider bean',
      'create faqs content',
      'create file content',
      'create page content',
      'create url aliases',
      'customize shortcut links',
      'delete any block bean',
      'delete any faqs content',
      'delete any file content',
      'delete any hero_unit bean',
      'delete any page content',
      'delete any slider bean',
      'delete own faqs content',
      'delete own file content',
      'delete own page content',
      'delete revisions',
      'edit any block bean',
      'edit any faqs content',
      'edit any file content',
      'edit any hero_unit bean',
      'edit any page content',
      'edit any slider bean',
      'edit cu blocks',
      'edit own faqs content',
      'edit own file content',
      'edit own page content',
      'execute node_assign_owner_action',
      'execute node_make_sticky_action',
      'execute node_make_unsticky_action',
      'execute node_promote_action',
      'execute node_publish_action',
      'execute node_unpromote_action',
      'execute node_unpublish_action',
      'execute node_unpublish_by_keyword_action',
      'execute views_bulk_operations_delete_item',
      'preview focal point',
      'revert revisions',
      'use bigmenu',
      'use text format wysiwyg',
      'view any hero_unit bean',
      'view any slider bean',
      'view bean page',
      'view bean revisions',
      'view any unpublished content',
      'view revisions',
      'view the administration theme',
      'access navbar',
      'view status messages',
      'view warning messages',
      'view error messages',
    ),
    'developer' => array(
      'access administration pages',
      'access all views',
      'access bean overview',
      'access ckeditor link',
      'access configuration administration',
      'access content',
      'access content overview',
      'access contextual links',
      'access cu version information',
      'access environment indicator',
      'access site in maintenance mode',
      'access site reports',
      'access user profiles',
      'access users overview',
      'access_google_appliance_content',
      'administer actions',
      'administer bean settings',
      'administer bean types',
      'administer beans',
      'administer bigmenu',
      'administer blocks',
      'administer boxes',
      'administer CAPTCHA settings',
      'administer checked out documents',
      'administer ckeditor link',
      'administer content types',
      'administer contexts',
      'administer cu alerts',
      'administer express settings',
      'administer express theme picker',
      'administer features',
      'administer fields',
      'administer field collections',
      'administer fieldgroups',
      'administer filters',
      'administer fitvids',
      'administer flexslider',
      'administer google analytics',
      'administer honeypot',
      'administer image styles',
      'administer menu',
      'administer meta tags',
      'administer modernizr',
      'administer module filter',
      'administer modules',
      'administer nodes',
      'administer people settings',
      'administer pathauto',
      'administer permissions',
      'administer recaptcha',
      'administer redirect settings',
      'administer redirects',
      'administer shortcuts',
      'administer site configuration',
      'administer software updates',
      'administer string overrides',
      'administer system menus',
      'administer taxonomy',
      'administer themes',
      'administer url aliases',
      'administer users',
      'administer video styles',
      'administer views',
      'administer_google_appliance',
      'admin_display_suite',
      'assign administrator role',
      'assign all roles',
      'assign content_editor role',
      'assign developer role',
      'assign edit_my_content role',
      'assign site_owner role',
      'block IP addresses',
      'bypass follow form validation',
      'cancel account',
      'change administration theme',
      'change own username',
      'check out documents',
      'context ajax block access',
      'create any block bean',
      'create any feature_callout bean',
      'create any hero_unit bean',
      'create any slider bean',
      'create faqs content',
      'create file content',
      'create page content',
      'create person content',
      'create url aliases',
      'create vocabulary',
      'customize shortcut links',
      'delete any block bean',
      'delete any faqs content',
      'delete any file content',
      'delete any hero_unit bean',
      'delete any page content',
      'delete any slider bean',
      'delete own faqs content',
      'delete own file content',
      'delete own page content',
      'delete revisions',
      'edit any block bean',
      'edit any faqs content',
      'edit any file content',
      'edit any hero_unit bean',
      'edit any page content',
      'edit any slider bean',
      'edit bean view mode',
      'edit boxes',
      'edit cu blocks',
      'edit locked contexts',
      'edit meta tags',
      'edit own faqs content',
      'edit own file content',
      'edit own page content',
      'execute node_assign_owner_action',
      'execute node_make_sticky_action',
      'execute node_make_unsticky_action',
      'execute node_promote_action',
      'execute node_publish_action',
      'execute node_unpromote_action',
      'execute node_unpublish_action',
      'execute node_unpublish_by_keyword_action',
      'execute views_bulk_operations_delete_item',
      'export secure permissions',
      'generate features',
      'invite new user',
      'manage features',
      'notify of path changes',
      'opt-in or out of tracking',
      'preview focal point',
      'revert revisions',
      'select account cancellation method',
      'switch shortcut sets',
      'use bigmenu',
      'use PHP for tracking visibility',
      'use text format full_html',
      'use text format wysiwyg',
      'view any block bean',
      'view any hero_unit bean',
      'view any slider bean',
      'view any unpublished content',
      'view bean page',
      'view bean revisions',
      'view own unpublished content',
      'view revisions',
      'view the administration theme',
      'access navbar',
      'enable module bundles',
      'enable admin bundles',
      'view status messages',
      'view warning messages',
      'view error messages',
      'exclude from message filtering',
    ),
    'edit_my_content' => array(
      'access ckeditor link',
      'access content overview',
      'access_google_appliance_content',
      'administer nodes',
      'check out documents',
      'edit own page content',
      'edit own person content',
      'preview focal point',
      'skip CAPTCHA',
      'use text format wysiwyg',
      'view any block bean',
      'view any feature_callout bean',
      'view any hero_unit bean',
      'view any quicktab bean',
      'view any slider bean',
      'view the administration theme',
      'access navbar',
      'view status messages',
      'view warning messages',
      'view error messages',
    ),
    'site_owner' => array(
      'access administration pages',
      'access bean overview',
      'access ckeditor link',
      'access content',
      'access content overview',
      'access contextual links',
      'access user profiles',
      'access users overview',
      'access_google_appliance_content',
      'administer beans',
      'administer blocks',
      'administer checked out documents',
      'administer contexts',
      'administer express settings',
      'administer express theme picker',
      'administer menu',
      'administer nodes',
      'administer people settings',
      'administer redirects',
      'assign content_editor role',
      'assign edit_my_content role',
      'assign site_owner role',
      'cancel users with role authenticated user',
      'cancel users with role content_editor',
      'cancel users with role edit_my_content',
      'cancel users with role site_owner',
      'check out documents',
      'create any block bean',
      'create any feature_callout bean',
      'create any hero_unit bean',
      'create any slider bean',
      'create faqs content',
      'create file content',
      'create page content',
      'create url aliases',
      'customize shortcut links',
      'delete any block bean',
      'delete any faqs content',
      'delete any file content',
      'delete any hero_unit bean',
      'delete any page content',
      'delete any slider bean',
      'delete own faqs content',
      'delete own file content',
      'delete own page content',
      'delete revisions',
      'edit any block bean',
      'edit any faqs content',
      'edit any file content',
      'edit any hero_unit bean',
      'edit any page content',
      'edit any slider bean',
      'edit cu blocks',
      'edit own faqs content',
      'edit own file content',
      'edit own page content',
      'edit users with role authenticated user',
      'edit users with role content_editor',
      'edit users with role edit_my_content',
      'edit users with role site_owner',
      'execute node_assign_owner_action',
      'execute node_make_sticky_action',
      'execute node_make_unsticky_action',
      'execute node_promote_action',
      'execute node_publish_action',
      'execute node_unpromote_action',
      'execute node_unpublish_action',
      'execute node_unpublish_by_keyword_action',
      'execute views_bulk_operations_delete_item',
      'invite new user',
      'preview focal point',
      'revert revisions',
      'use bigmenu',
      'use text format wysiwyg',
      'view any block bean',
      'view any hero_unit bean',
      'view any slider bean',
      'view any unpublished content',
      'view bean page',
      'view bean revisions',
      'view own unpublished content',
      'view revisions',
      'view the administration theme',
      'access navbar',
      'enable module bundles',
      'view status messages',
      'view warning messages',
      'view error messages',
    ),
  );
  if (isset($permissions[$role])) {
    return $permissions[$role];
  }
}