You are here

function group_group_filters in Group 7

Implements hook_group_filters().

File

./group.group.inc, line 81
Hook implementations for the Group module.

Code

function group_group_filters() {

  // Get a list of all group types.
  $group_types = array();
  foreach (group_types() as $name => $group_type) {
    $group_types[$name] = $group_type
      ->label();
  }

  // Build a group type filter.
  $filters['type'] = array(
    'title' => t('Group type'),
    'options' => array(
      '[any]' => t('any'),
    ) + $group_types,
  );
  return $filters;
}