public function DeleteRegistrationPageForm::submitForm in Multiple Registration 8.2
Same name and namespace in other branches
- 8 src/Form/DeleteRegistrationPageForm.php \Drupal\multiple_registration\Form\DeleteRegistrationPageForm::submitForm()
- 3.x src/Form/DeleteRegistrationPageForm.php \Drupal\multiple_registration\Form\DeleteRegistrationPageForm::submitForm()
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/ DeleteRegistrationPageForm.php, line 88
Class
- DeleteRegistrationPageForm
- Class DeleteRegistrationPageForm.
Namespace
Drupal\multiple_registration\FormCode
public function submitForm(array &$form, FormStateInterface $form_state) {
$rid = $form_state
->getValue('rid');
$clicked_button = end($form_state
->getTriggeringElement()['#parents']);
switch ($clicked_button) {
case 'remove':
if ($rid) {
$this->multipleRegistrationController
->removeRegisterPage($rid);
}
break;
}
$form_state
->setRedirect('multiple_registration.multiple_registration_list_index');
}