public function UserData::buildOptionsForm

Overrides \Drupal\views\Plugin\views\field\FieldPluginBase::defineOptions().

Overrides FieldPluginBase::buildOptionsForm

File

drupal/core/modules/user/lib/Drupal/user/Plugin/views/field/UserData.php, line 58
Contains \Drupal\user\Plugin\views\field\UserData.

Class

UserData
Provides access to the user data service.

Namespace

Drupal\user\Plugin\views\field

Code

public function buildOptionsForm(&$form, &$form_state) {
  parent::buildOptionsForm($form, $form_state);
  $form['module'] = array(
    '#title' => t('Module name'),
    '#type' => 'select',
    '#description' => t('The module which sets this user data.'),
    '#default_value' => $this->options['module'],
    '#options' => system_get_module_info('name'),
  );
  $form['name'] = array(
    '#title' => t('Name'),
    '#type' => 'textfield',
    '#description' => t('The name of the data key.'),
    '#default_value' => $this->options['name'],
  );
}