public function DefaultsEntityForm::redirectOnSubmit in Drupal 9
Same name and namespace in other branches
- 8 core/modules/layout_builder/src/Form/DefaultsEntityForm.php \Drupal\layout_builder\Form\DefaultsEntityForm::redirectOnSubmit()
- 10 core/modules/layout_builder/src/Form/DefaultsEntityForm.php \Drupal\layout_builder\Form\DefaultsEntityForm::redirectOnSubmit()
Form submission handler.
File
- core/
modules/ layout_builder/ src/ Form/ DefaultsEntityForm.php, line 192
Class
- DefaultsEntityForm
- Provides a form containing the Layout Builder UI for defaults.
Namespace
Drupal\layout_builder\FormCode
public function redirectOnSubmit(array $form, FormStateInterface $form_state) {
$form_state
->setRedirectUrl($this->sectionStorage
->getLayoutBuilderUrl($form_state
->getTriggeringElement()['#redirect']));
}