public function SettingsForm::submitForm in Module Builder 8.3
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 81
Class
- SettingsForm
- Form for configuring Module Builder.
Namespace
Drupal\module_builder\FormCode
public function submitForm(array &$form, FormStateInterface $form_state) {
$this
->config('module_builder.settings')
->set('data_directory', $form_state
->getValue('data_directory'))
->set('generator_settings.module', $form_state
->getValue('generator_settings_module'))
->save();
parent::submitForm($form, $form_state);
}