function EntityLabel::buildOptionsForm
Same name in other branches
- 8.9.x core/modules/views/src/Plugin/views/field/EntityLabel.php \Drupal\views\Plugin\views\field\EntityLabel::buildOptionsForm()
- 10 core/modules/views/src/Plugin/views/field/EntityLabel.php \Drupal\views\Plugin\views\field\EntityLabel::buildOptionsForm()
- 11.x core/modules/views/src/Plugin/views/field/EntityLabel.php \Drupal\views\Plugin\views\field\EntityLabel::buildOptionsForm()
Overrides FieldPluginBase::buildOptionsForm
File
-
core/
modules/ views/ src/ Plugin/ views/ field/ EntityLabel.php, line 85
Class
- EntityLabel
- Field handler to display entity label optionally linked to entity page.
Namespace
Drupal\views\Plugin\views\fieldCode
public function buildOptionsForm(&$form, FormStateInterface $form_state) {
$form['link_to_entity'] = [
'#title' => $this->t('Link to entity'),
'#description' => $this->t('Make entity label a link to entity page.'),
'#type' => 'checkbox',
'#default_value' => !empty($this->options['link_to_entity']),
];
parent::buildOptionsForm($form, $form_state);
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.