You are here

function ctools_access_group_summary in Chaos Tool Suite (ctools) 6

Same name and namespace in other branches
  1. 7 includes/context.inc \ctools_access_group_summary()

Get a summary of a group of access plugin's settings.

2 calls to ctools_access_group_summary()
page_manager_http_response_admin_summary in page_manager/plugins/task_handlers/http_response.inc
page_manager_page_admin_summary in page_manager/plugins/tasks/page.inc
Provide a nice administrative summary of the page so an admin can see at a glance what this page does and how it is configured.

File

includes/context.inc, line 1380
Contains code related to the ctools system of 'context'.

Code

function ctools_access_group_summary($access, $contexts) {
  if (empty($access['plugins'])) {
    return;
  }
  $descriptions = array();
  foreach ($access['plugins'] as $id => $test) {
    $plugin = ctools_get_access_plugin($test['name']);
    $descriptions[] = ctools_access_summary($plugin, $contexts, $test);
  }
  $separator = $access['logic'] == 'and' ? t(', and ') : t(', or ');
  return implode($separator, $descriptions);
}