1 views_handler_filter_in_operator.inc views_handler_filter_in_operator::accept_exposed_input($input)

Check to see if input from the exposed filters should change the behavior of this filter.

Overrides views_handler_filter::accept_exposed_input

File

core/modules/views/handlers/views_handler_filter_in_operator.inc, line 272
Definition of views_handler_filter_in_operator.

Class

views_handler_filter_in_operator
Simple filter to handle matching of multiple options selectable via checkboxes

Code

function accept_exposed_input($input) {
  // A very special override because the All state for this type of
  // filter could have a default:
  if (empty($this->options['exposed'])) {
    return TRUE;
  }

  // If this is non-multiple and non-required, then this filter will
  // participate, but using the default settings, *if* 'limit is true.
  if (empty($this->options['expose']['multiple']) && empty($this->options['expose']['required']) && !empty($this->options['expose']['limit'])) {
    $identifier = $this->options['expose']['identifier'];
    if ($input[$identifier] == 'All') {
      return TRUE;
    }
  }

  return parent::accept_exposed_input($input);
}