public function ListString::buildOptionsForm

Build the options form.

Overrides String::buildOptionsForm

File

drupal/core/modules/field/lib/Drupal/field/Plugin/views/argument/ListString.php, line 48
Definition of Drupal\field\Plugin\views\argument\ListString.

Class

ListString
Argument handler for list field to show the human readable name in the summary.

Namespace

Drupal\field\Plugin\views\argument

Code

public function buildOptionsForm(&$form, &$form_state) {
  parent::buildOptionsForm($form, $form_state);
  $form['summary']['human'] = array(
    '#title' => t('Display list value as human readable'),
    '#type' => 'checkbox',
    '#default_value' => $this->options['summary']['human'],
    '#states' => array(
      'visible' => array(
        ':input[name="options[default_action]"]' => array(
          'value' => 'summary',
        ),
      ),
    ),
  );
}