public function ServerStatusForm::submitForm in Search API 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 FormInterface::submitForm
File
- src/
Form/ ServerStatusForm.php, line 116
Class
- ServerStatusForm
- Provides a form for performing common actions on a server.
Namespace
Drupal\search_api\FormCode
public function submitForm(array &$form, FormStateInterface $form_state) {
// Redirect to the "Clear server" confirmation form.
/** @var \Drupal\search_api\ServerInterface $server */
$server = $form['#server'];
$form_state
->setRedirect('entity.search_api_server.clear', [
'search_api_server' => $server
->id(),
]);
}