You are here

public function SettingsForm::submitForm in BigBlueButton 8

Same name in this branch
  1. 8 src/Form/SettingsForm.php \Drupal\bbb\Form\SettingsForm::submitForm()
  2. 8 modules/bbb_node/src/Form/SettingsForm.php \Drupal\bbb_node\Form\SettingsForm::submitForm()

Form submission handler.

Parameters

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

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

Overrides ConfigFormBase::submitForm

File

src/Form/SettingsForm.php, line 93

Class

SettingsForm
Provides an administration settings form.

Namespace

Drupal\bbb\Form

Code

public function submitForm(array &$form, FormStateInterface $form_state) {

  // Get config factory.
  $config = $this->configFactory
    ->getEditable('bbb.settings');
  $form_values = $form_state
    ->getValues();
  $config
    ->set('security_salt', $form_values['bbb_server']['security_salt'])
    ->set('base_url', $form_values['bbb_server']['base_url'])
    ->save();
  parent::submitForm($form, $form_state);
}