public function CrazyeggSettingsForm::submitForm in Crazy Egg Integration 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/ CrazyeggSettingsForm.php, line 30 - Contains Drupal\crazyegg\Form\CrazyeggSettingsForm.
Class
- CrazyeggSettingsForm
- Returns responses for Crazyegg module routes.
Namespace
Drupal\crazyegg\FormCode
public function submitForm(array &$form, FormStateInterface $form_state) {
$this
->config('crazyegg.settings')
->set('crazyegg_enabled', $form_state
->getValue('crazyegg_enabled'))
->set('crazyegg_account_id', $form_state
->getValue('crazyegg_account_id'))
->set('crazyegg_js_scope', $form_state
->getValue('crazyegg_js_scope'))
->set('crazyegg_roles_excluded', $form_state
->getValue('crazyegg_roles_excluded'))
->set('crazyegg_paths', $form_state
->getValue('crazyegg_paths'))
->save();
if (method_exists($this, '_submitForm')) {
$this
->_submitForm($form, $form_state);
}
parent::submitForm($form, $form_state);
}