public function ActionWebformHandler::submitConfigurationForm in Webform 6.x
Same name and namespace in other branches
- 8.5 src/Plugin/WebformHandler/ActionWebformHandler.php \Drupal\webform\Plugin\WebformHandler\ActionWebformHandler::submitConfigurationForm()
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 WebformHandlerBase::submitConfigurationForm
File
- src/
Plugin/ WebformHandler/ ActionWebformHandler.php, line 234
Class
- ActionWebformHandler
- Webform submission action handler.
Namespace
Drupal\webform\Plugin\WebformHandlerCode
public function submitConfigurationForm(array &$form, FormStateInterface $form_state) {
parent::submitConfigurationForm($form, $form_state);
$this
->applyFormStateToConfiguration($form_state);
// Cleanup states.
$this->configuration['states'] = array_values(array_filter($this->configuration['states']));
// Cleanup sticky.
if ($form_state
->getValue('sticky') === '') {
$this->configuration['sticky'] = NULL;
}
// Cleanup locked.
if ($form_state
->getValue('locked') === '') {
$this->configuration['locked'] = NULL;
}
}