public function EntityBrowser::buildOptionsForm in Entity Browser 8
Same name and namespace in other branches
- 8.2 src/Plugin/views/display/EntityBrowser.php \Drupal\entity_browser\Plugin\views\display\EntityBrowser::buildOptionsForm()
Provide a form to edit options for this plugin.
Overrides DisplayPluginBase::buildOptionsForm
File
- src/
Plugin/ views/ display/ EntityBrowser.php, line 85
Class
- EntityBrowser
- The plugin that handles entity browser display.
Namespace
Drupal\entity_browser\Plugin\views\displayCode
public function buildOptionsForm(&$form, FormStateInterface $form_state) {
parent::buildOptionsForm($form, $form_state);
// Disable the ability to toggle AJAX support, as we forcibly enable AJAX
// in our ajaxEnabled() implementation.
if (isset($form['use_ajax'])) {
$form['use_ajax'] = [
'#description' => $this
->t('Entity Browser requires Views to use AJAX.'),
'#type' => 'checkbox',
'#title' => $this
->t('Use AJAX'),
'#default_value' => 1,
'#disabled' => TRUE,
];
}
}