public function WebformSignature::buildExportRecord in Webform 8.5
Same name and namespace in other branches
- 6.x src/Plugin/WebformElement/WebformSignature.php \Drupal\webform\Plugin\WebformElement\WebformSignature::buildExportRecord()
Build an element's export row.
Parameters
array $element: An element.
\Drupal\webform\WebformSubmissionInterface $webform_submission: A webform submission.
array $export_options: An associative array of export options.
Return value
array An array containing the element's export row.
Overrides WebformElementBase::buildExportRecord
See also
\Drupal\webform\WebformSubmissionExporterInterface::getDefaultExportOptions
File
- src/
Plugin/ WebformElement/ WebformSignature.php, line 230
Class
- WebformSignature
- Provides a 'signature' element.
Namespace
Drupal\webform\Plugin\WebformElementCode
public function buildExportRecord(array $element, WebformSubmissionInterface $webform_submission, array $export_options) {
$element['#format'] = $export_options['signature_format'] === 'status' ? 'image' : 'raw';
return [
$this
->formatText($element, $webform_submission, $export_options),
];
}