Passing list of object in Email Template

Hi everyone, I am using the Email Template module for sending the emails to users. As of now i am sending only one object in email. but i want to send list of object in one email. So i wanted to know that whether we can send list of objects in email or not. And if its is possible than please if anyone can suggest the way of doing it in microflow and how to fetch it in Email Template prepared for that email. Secondly Can we also show the data in form of table in html in email because when I am trying to create a table in Email Template then while sending the email the data is not sending in form of table but its going as normal text instead in form of table. I am using Mendix 8.12.1 version.
1 answers

Hi Prakhar,

As per my understanding, the Email Template module allows you to create placeholders from One object Only. The tokens can take the values from an attribute or from a reference. Both of these options don't support a List to take the replaceable values.

You can achieve this by implementing a custom Microflow to create an HTML Message body using Java Activity (By Iterating through the List and manipulating the HTML <TR><TD> Elements in a list. You have to modify the Microflow (SUB_CreateAndSendEmail to insert the Table HTML into the Email body after replacing the tokens. Hope this helps