public function PanelizerWizardGeneralForm::submitForm in Panelizer 8.4
Same name and namespace in other branches
- 8.5 src/Form/PanelizerWizardGeneralForm.php \Drupal\panelizer\Form\PanelizerWizardGeneralForm::submitForm()
- 8.3 src/Form/PanelizerWizardGeneralForm.php \Drupal\panelizer\Form\PanelizerWizardGeneralForm::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/ PanelizerWizardGeneralForm.php, line 145
Class
- PanelizerWizardGeneralForm
- General settings for a panelized bundle.
Namespace
Drupal\panelizer\FormCode
public function submitForm(array &$form, FormStateInterface $form_state) {
$cached_values = $form_state
->getTemporaryValue('wizard');
/** @var \Drupal\panels\Plugin\DisplayVariant\PanelsDisplayVariant $plugin */
$plugin = $cached_values['plugin'];
$plugin
->submitConfigurationForm($form['variant_settings'], (new FormState())
->setValues($form_state
->getValue('variant_settings', [])));
$configuration = $plugin
->getConfiguration();
$cached_values['plugin']
->setConfiguration($configuration);
}