public function Extension::buildOptionsForm

Default options form that provides the label widget that all fields should have.

Overrides FieldPluginBase::buildOptionsForm

File

drupal/core/modules/file/lib/Drupal/file/Plugin/views/field/Extension.php, line 34
Definition of views_handler_field_file_extension.

Class

Extension
Returns a pure file extension of the file, for example 'module'.

Namespace

Drupal\file\Plugin\views\field

Code

public function buildOptionsForm(&$form, &$form_state) {
  parent::buildOptionsForm($form, $form_state);
  $form['extension_detect_tar'] = array(
    '#type' => 'checkbox',
    '#title' => t('Detect if tar is part of the extension'),
    '#description' => t("See if the previous extension is '.tar' and if so, add that, so we see 'tar.gz' or 'tar.bz2' instead of just 'gz'."),
    '#default_value' => $this->options['extension_detect_tar'],
  );
}