You are here

public function TrumbaConfigurationForm::buildForm in Trumba 8

Same name and namespace in other branches
  1. 2.x src/Form/TrumbaConfigurationForm.php \Drupal\trumba\Form\TrumbaConfigurationForm::buildForm()

Form constructor.

Parameters

array $form: An associative array containing the structure of the form.

\Drupal\Core\Form\FormStateInterface $form_state: The current state of the form.

Return value

array The form structure.

Overrides ConfigFormBase::buildForm

File

src/Form/TrumbaConfigurationForm.php, line 34

Class

TrumbaConfigurationForm
Class TrumbaConfigurationForm.

Namespace

Drupal\trumba\Form

Code

public function buildForm(array $form, FormStateInterface $form_state) {
  $config = $this
    ->config('trumba.trumbaconfiguration');
  $form['default_web_name'] = [
    '#type' => 'textfield',
    '#title' => $this
      ->t('Default Web Name'),
    '#description' => $this
      ->t('This is the default unique identifier for your account on Trumba.'),
    '#maxlength' => 255,
    '#size' => 64,
    '#default_value' => $config
      ->get('default_web_name'),
  ];
  return parent::buildForm($form, $form_state);
}