public function WebformSubmissionExporter::generate in Webform 6.x
Same name and namespace in other branches
- 8.5 src/WebformSubmissionExporter.php \Drupal\webform\WebformSubmissionExporter::generate()
Execute results exporter and write export to a temp file.
Overrides WebformSubmissionExporterInterface::generate
File
- src/
WebformSubmissionExporter.php, line 786
Class
- WebformSubmissionExporter
- Webform submission exporter.
Namespace
Drupal\webformCode
public function generate() {
$entity_ids = $this
->getQuery()
->execute();
$webform_submissions = WebformSubmission::loadMultiple($entity_ids);
$this
->writeHeader();
$this
->writeRecords($webform_submissions);
$this
->writeFooter();
}