You are here

protected function FilterPluginBase::canBuildGroup in Drupal 8

Same name and namespace in other branches
  1. 9 core/modules/views/src/Plugin/views/filter/FilterPluginBase.php \Drupal\views\Plugin\views\filter\FilterPluginBase::canBuildGroup()

Determine if a filter can be converted into a group. Only exposed filters with operators available can be converted into groups.

1 call to FilterPluginBase::canBuildGroup()
FilterPluginBase::buildOptionsForm in core/modules/views/src/Plugin/views/filter/FilterPluginBase.php
Provide the basic form which calls through to subforms. If overridden, it is best to call through to the parent, or to at least make sure all of the functions in this form are called.

File

core/modules/views/src/Plugin/views/filter/FilterPluginBase.php, line 190

Class

FilterPluginBase
Base class for Views filters handler plugins.

Namespace

Drupal\views\Plugin\views\filter

Code

protected function canBuildGroup() {
  return $this
    ->isExposed() && count($this
    ->operatorOptions()) > 0;
}