function PluginBase::buildOptionsForm

Same name and namespace in other branches
  1. 11.x core/modules/views/src/Plugin/views/PluginBase.php \Drupal\views\Plugin\views\PluginBase::buildOptionsForm()
  2. 10 core/modules/views/src/Plugin/views/PluginBase.php \Drupal\views\Plugin\views\PluginBase::buildOptionsForm()
  3. 8.9.x core/modules/views/src/Plugin/views/PluginBase.php \Drupal\views\Plugin\views\PluginBase::buildOptionsForm()
1 method overrides PluginBase::buildOptionsForm()
RowPluginBase::buildOptionsForm in core/modules/views/src/Plugin/views/row/RowPluginBase.php
Provide a form for setting options.

File

core/modules/views/src/Plugin/views/PluginBase.php, line 268

Class

PluginBase
Base class for any views plugin types.

Namespace

Drupal\views\Plugin\views

Code

public function buildOptionsForm(&$form, FormStateInterface $form_state) {
  // Some form elements belong in a fieldset for presentation, but can't
  // be moved into one because of the $form_state->getValues() hierarchy. Those
  // elements can add a #fieldset => 'fieldset_name' property, and they'll
  // be moved to their fieldset during pre_render.
  $form['#pre_render'][] = [
    static::class,
    'preRenderAddFieldsetMarkup',
  ];
}

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.