You are here

public function InputRequired::buildOptionsForm in Views (for Drupal 7) 8.3

Provide a form to edit options for this plugin.

Overrides ExposedFormPluginBase::buildOptionsForm

File

lib/Drupal/views/Plugin/views/exposed_form/InputRequired.php, line 34
Definition of Drupal\views\Plugin\views\exposed_form\InputRequired.

Class

InputRequired
Exposed form plugin that provides an exposed form with required input.

Namespace

Drupal\views\Plugin\views\exposed_form

Code

public function buildOptionsForm(&$form, &$form_state) {
  parent::buildOptionsForm($form, $form_state);
  $form['text_input_required'] = array(
    '#type' => 'text_format',
    '#title' => t('Text on demand'),
    '#description' => t('Text to display instead of results until the user selects and applies an exposed filter.'),
    '#default_value' => $this->options['text_input_required'],
    '#format' => isset($this->options['text_input_required_format']) ? $this->options['text_input_required_format'] : filter_default_format(),
    '#wysiwyg' => FALSE,
  );
}