I have a webform containing nested elements, i.e.: container element > email field.

When the email field is nested, it is not selectable when adding a new mailchimp handler.

Work-around is possible:
- Move the email field to the root of the webform makes it selectable
- Select the email field and save the settings for mailchimp
- Move the field back to the nested position again

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

Eric van der Staaij created an issue. See original summary.

tijsdeboeck’s picture

Indeed, noticed the same issue just now, and did ty the same work-around, which works.

maio1980’s picture

And use
$fields = $this->getWebform()->getElementsInitializedAndFlattened();
instead of
$fields = $this->getWebform()->getElementsDecoded();
on line 111 in WebformMailChimpHandler.php ?

autopoietic’s picture

#3 works for me, thanks maio1980. Here is a patch against 8.x-5.x-dev. Fixes an unrelated typo also.

autopoietic’s picture

Status: Active » Needs review
mbovan’s picture

Status: Needs review » Reviewed & tested by the community

#4 works for me as well.

mbovan’s picture

Status: Reviewed & tested by the community » Closed (duplicate)
Related issues: +#2847658: Use getElementsInitializedAndFlattened in place of getElementsDecoded