Send Email step was introduced in AEM Forms 6.4. Using this step we can build business processes or workflow which will allow you to send emails with or without attachments. The following video walks through the steps for configuring the send email component.
As part of this article, we will walk you through the following use case:
Before you use Send Email step make sure you configure the Day CQ Mail Service from the configMgr. Provide the values specific to your environment
As part of the assets associated with this article, You will get the following
To get the sample running on your system, please do the following:
Download and install setvalue bundleThis bundle contains the code for creating the metadata properties as part of the process step of the workflow.
Launch the adaptive form. Fill in the required fields and submit.
You should get an email with DocumentOfRecord as an attachment
Explore the workflow model
Take a look at the process step of the workflow. The custom code associated with the process step will create metadata property names and sets its values from the submitted data.These values are then used by the send email component.
In AEM Forms 6.5 and above you do not need this custom code to create metadata properties. Please use the variables capability in AEM Workflow
Make sure the Attachments tab of the Send Email component is configured as per the screen shot below
The “DOR.pdf” value has to match the value specified in the Document of Record Path specified in the submission options of your adaptive form.