You are here

protected function ManyToOne::valueForm in Drupal 10

Same name and namespace in other branches
  1. 8 core/modules/views/src/Plugin/views/filter/ManyToOne.php \Drupal\views\Plugin\views\filter\ManyToOne::valueForm()
  2. 9 core/modules/views/src/Plugin/views/filter/ManyToOne.php \Drupal\views\Plugin\views\filter\ManyToOne::valueForm()

Options form subform for setting options.

This should be overridden by all child classes and it must define $form['value']

Overrides InOperator::valueForm

See also

buildOptionsForm()

1 method overrides ManyToOne::valueForm()
TaxonomyIndexTid::valueForm in core/modules/taxonomy/src/Plugin/views/filter/TaxonomyIndexTid.php
Options form subform for setting options.

File

core/modules/views/src/Plugin/views/filter/ManyToOne.php, line 107

Class

ManyToOne
Complex filter to handle filtering for many to one relationships, such as terms (many terms per node) or roles (many roles per user).

Namespace

Drupal\views\Plugin\views\filter

Code

protected function valueForm(&$form, FormStateInterface $form_state) {
  parent::valueForm($form, $form_state);
  if (!$form_state
    ->get('exposed')) {
    $this->helper
      ->buildOptionsForm($form, $form_state);
  }
}