public function CleanPagerSettingsForm::submitForm in Clean Pagination 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/ CleanPagerSettingsForm.php, line 61
Class
- CleanPagerSettingsForm
- Defines a form to configure module settings.
Namespace
Drupal\cleanpager\FormCode
public function submitForm(array &$form, FormStateInterface $form_state) {
$config = $this
->configFactory()
->getEditable('cleanpager.settings');
$form_values = $form_state
->getValues();
$config
->set('cleanpager_pages', $form_values['settings']['cleanpager_pages'])
->set('cleanpager_add_trailing', $form_values['settings']['cleanpager_add_trailing'])
->save();
parent::submitForm($form, $form_state);
}