public function PrintEngineBase::submitConfigurationForm in Entity Print 8.2
Form submission handler.
Parameters
array $form: An associative array containing the structure of the plugin form as built by static::buildConfigurationForm().
\Drupal\Core\Form\FormStateInterface $form_state: The current state of the form. Calling code should pass on a subform state created through \Drupal\Core\Form\SubformState::createForSubform().
Overrides PluginFormInterface::submitConfigurationForm
2 methods override PrintEngineBase::submitConfigurationForm()
- TestPrintEngine::submitConfigurationForm in tests/
modules/ entity_print_test/ src/ Plugin/ EntityPrint/ PrintEngine/ TestPrintEngine.php - Form submission handler.
- TestWordPrintEngine::submitConfigurationForm in tests/
modules/ entity_print_test/ src/ Plugin/ EntityPrint/ PrintEngine/ TestWordPrintEngine.php - Form submission handler.
File
- src/
Plugin/ PrintEngineBase.php, line 79
Class
- PrintEngineBase
- The PrintEngineBase class.
Namespace
Drupal\entity_print\PluginCode
public function submitConfigurationForm(array &$form, FormStateInterface $form_state) {
$values = OptGroup::flattenOptions($form_state
->getValues());
foreach ($this
->defaultConfiguration() as $key => $value) {
$this->configuration[$key] = isset($values[$key]) ? $values[$key] : NULL;
}
}