public function FormTestRebuildPreserveValuesForm::addMoreSubmitForm in Zircon Profile 8.0
Same name and namespace in other branches
- 8 core/modules/system/tests/modules/form_test/src/Form/FormTestRebuildPreserveValuesForm.php \Drupal\form_test\Form\FormTestRebuildPreserveValuesForm::addMoreSubmitForm()
File
- core/
modules/ system/ tests/ modules/ form_test/ src/ Form/ FormTestRebuildPreserveValuesForm.php, line 89 - Contains \Drupal\form_test\Form\FormTestRebuildPreserveValuesForm.
Class
- FormTestRebuildPreserveValuesForm
- Form builder for testing preservation of values during a rebuild.
Namespace
Drupal\form_test\FormCode
public function addMoreSubmitForm(array &$form, FormStateInterface $form_state) {
// Rebuild, to test preservation of input values.
$form_state
->set('add_more', TRUE);
$form_state
->setRebuild();
}