/** * {@inheritdoc} */ public function submitForm(array &$form, FormStateInterface $form_state) { $config = $this->config('cas.settings'); $server_data = $form_state->getValue('server'); $config->set('server.version', $server_data['version'])->set('server.hostname', $server_data['hostname'])->set('server.port', $server_data['port'])->set('server.path', $server_data['path'])->set('server.cert', $server_data['cert']); $condition_values = (new FormState())->setValues($form_state->getValue(['gateway', 'paths'])); $this->gatewayPaths->submitConfigurationForm($form, $condition_values); $config->set('gateway.check_frequency', $form_state->getValue(['gateway', 'check_frequency']))->set('gateway.paths', $this->gatewayPaths->getConfiguration()); $condition_values = (new FormState())->setValues($form_state->getValue(['forced_login', 'paths'])); $this->forcedLoginPaths->submitConfigurationForm($form, $condition_values); $config->set('forced_login.enabled', $form_state->getValue(['forced_login', 'enabled']))->set('forced_login.paths', $this->forcedLoginPaths->getConfiguration()); $config->set('redirection.logout_destination', $form_state->getValue(['redirection', 'logout_destination'])); $config->set('proxy.initialize', $form_state->getValue(['proxy', 'initialize']))->set('proxy.can_be_proxied', $form_state->getValue(['proxy', 'can_be_proxied']))->set('proxy.proxy_chains', $form_state->getValue(['proxy', 'proxy_chains'])); $config->set('user_accounts.auto_register', $form_state->getValue(['user_accounts', 'auto_register'])); $config->set('debugging.log', $form_state->getValue(['debugging', 'log'])); $config->save(); parent::submitForm($form, $form_state); }