public function WebformTestElement::postSave in Webform 8.5
Same name and namespace in other branches
- 6.x tests/modules/webform_test_element/src/Plugin/WebformElement/WebformTestElement.php \Drupal\webform_test_element\Plugin\WebformElement\WebformTestElement::postSave()
Acts on a saved webform submission element before the insert or update hook is invoked.
Parameters
array $element: An element.
\Drupal\webform\WebformSubmissionInterface $webform_submission: A webform submission.
bool $update: TRUE if the entity has been updated, or FALSE if it has been inserted.
Overrides WebformElementBase::postSave
File
- tests/
modules/ webform_test_element/ src/ Plugin/ WebformElement/ WebformTestElement.php, line 111
Class
- WebformTestElement
- Provides a 'webform_test_element' element.
Namespace
Drupal\webform_test_element\Plugin\WebformElementCode
public function postSave(array &$element, WebformSubmissionInterface $webform_submission, $update = TRUE) {
$this
->displayMessage(__FUNCTION__, $update ? 'update' : 'insert');
}