function OverridesEntityForm::save
Overrides EntityForm::save
File
-
core/
modules/ layout_builder/ src/ Form/ OverridesEntityForm.php, line 176
Class
- OverridesEntityForm
- Provides a form containing the Layout Builder UI for overrides.
Namespace
Drupal\layout_builder\FormCode
public function save(array $form, FormStateInterface $form_state) {
$return = parent::save($form, $form_state);
$this->layoutTempstoreRepository
->delete($this->sectionStorage);
$this->messenger()
->addStatus($this->t('The layout override has been saved.'));
$form_state->setRedirectUrl($this->sectionStorage
->getRedirectUrl());
return $return;
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.