You are here

public function SettingsForm::submitForm in Hashtags 8

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 73

Class

SettingsForm

Namespace

Drupal\hashtags\Form

Code

public function submitForm(array &$form, FormStateInterface $form_state) {
  $this
    ->config('hashtags.settings')
    ->set('hashtags_taxonomy_terms_field_name', $form_state
    ->getValue('hashtags_taxonomy_terms_field_name'))
    ->set('hashtags_vid', $form_state
    ->getValue('hashtags_vid'))
    ->set('hide_field_hashtags', $form_state
    ->getValue('hide_field_hashtags'))
    ->save();
  parent::submitForm($form, $form_state);
}