Skip to content
This repository was archived by the owner on Nov 27, 2023. It is now read-only.
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,10 @@ Versioning](https://semver.org/spec/v2.0.0.html).

## [Unreleased]

### Changed

- Added more recipient field types

## [1.1.0]

### Added
Expand Down
11 changes: 9 additions & 2 deletions src/Plugin/WebformHandler/WebformHandlerSF1601.php
Original file line number Diff line number Diff line change
Expand Up @@ -241,10 +241,17 @@ public function buildConfigurationForm(array $form, FormStateInterface $formStat
private function getRecipientElements(): array {
$elements = $this->getWebform()->getElementsDecodedAndFlattened();

$elementTypes = [
'textfield',
'cpr_element',
'cpr_value_element',
'cvr_element',
'cvr_value_element',
];
$elements = array_filter(
$elements,
static function (array $element) {
return in_array($element['#type'], ['textfield'], TRUE);
static function (array $element) use ($elementTypes) {
return in_array($element['#type'], $elementTypes, TRUE);
}
);

Expand Down