public function ContextualBundle::acceptExposedInput in Entity Browser 8
Same name and namespace in other branches
- 8.2 src/Plugin/views/filter/ContextualBundle.php \Drupal\entity_browser\Plugin\views\filter\ContextualBundle::acceptExposedInput()
Determines if the input from a filter should change the generated query.
Parameters
array $input: The exposed data for this view.
Return value
bool TRUE if the input for this filter should be included in the view query. FALSE otherwise.
Overrides InOperator::acceptExposedInput
File
- src/
Plugin/ views/ filter/ ContextualBundle.php, line 198
Class
- ContextualBundle
- Filter class which allows filtering by entity bundles.
Namespace
Drupal\entity_browser\Plugin\views\filterCode
public function acceptExposedInput($input) {
if (empty($this->options['exposed'])) {
return TRUE;
}
// If "All" option selected, Do call ::query.
$identifier = $this->options['expose']['identifier'];
if (!empty($input[$identifier]) && $input[$identifier] == 'All') {
return TRUE;
}
return parent::acceptExposedInput($input);
}