Set updated form state on the multistep controller before form rebuild

Created on 2 October 2024, about 2 months ago

Problem/Motivation

When rebuilding the form we may want the most recently input form values from form_state. In my scenario I need this as we use the form_state values to save the entity the form is for. I don't see any downsides to setting this form_state, it makes sense to me that the form_state would be up to date.

Steps to reproduce

Proposed resolution

In `simple_multistep_form_alter` just call `$multiStep->setFormState($form_state);` before calling `rebuildForm()`.

Remaining tasks

User interface changes

API changes

Data model changes

Feature request
Status

Active

Version

2.0

Component

Code

Created by

🇬🇧United Kingdom mjmorley

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

Production build 0.71.5 2024