You are here

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

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

Overrides FieldPluginBase::buildOptionsForm

File

lib/Views/comment/Plugin/views/field/Username.php, line 41
Definition of Views\comment\Plugin\views\field\Username.

Class

Username
Field handler to allow linking to a user account or homepage.

Namespace

Views\comment\Plugin\views\field

Code

public function buildOptionsForm(&$form, &$form_state) {
  $form['link_to_user'] = array(
    '#title' => t("Link this field to its user or an author's homepage"),
    '#type' => 'checkbox',
    '#default_value' => $this->options['link_to_user'],
  );
  parent::buildOptionsForm($form, $form_state);
}