My app allows users to create a list of Contacts via various searches, and then choose a set of actions on those contacts, such as sending them an email.
I’m a bit unclear about how to create the data structure to do this.
So far I have created an array of numbers called Contact List and used Add Unique to add the id of a chosen contact to the list.
With that I have created a repeat block which allows me to display… well, with my current knowledge, only the id values!
Is there a way I can access more useful information about the contact in this repeat, or do I need to create a more complex data structure that somehow gets initialised with fields such as first_name, last_name… when I do the Add Unique?
You can use the array values to filter a database query and show the results on the page, same for your send email - get the results of the filtered query.
You just need a server action with database query, filtered by the array items.
Then you create your repeat, which shows the details on the page out of this query, not using the array