You are here

public function WebformTestElement::preSave in Webform 8.5

Same name and namespace in other branches
  1. 6.x tests/modules/webform_test_element/src/Plugin/WebformElement/WebformTestElement.php \Drupal\webform_test_element\Plugin\WebformElement\WebformTestElement::preSave()

Acts on a webform submission element before the presave hook is invoked.

Parameters

array $element: An element.

\Drupal\webform\WebformSubmissionInterface $webform_submission: A webform submission.

Overrides WebformElementBase::preSave

File

tests/modules/webform_test_element/src/Plugin/WebformElement/WebformTestElement.php, line 97

Class

WebformTestElement
Provides a 'webform_test_element' element.

Namespace

Drupal\webform_test_element\Plugin\WebformElement

Code

public function preSave(array &$element, WebformSubmissionInterface $webform_submission) {
  $this
    ->displayMessage(__FUNCTION__);
}