Email product related

Fernando_Aguila
Member | Diamond Partner

I am doing a mail of related products, for each product line I am filtering by product name in a HubDB table, but I have a problem, I cannot operate with the varible line_item, I can only print it on the screen, but I cannot apply filters, compare the variable with another variable


{% email_each list="deal.line_items" item="line_item" %}
{%set name=line_item.name%}
{{name}}
{%set productos=hubdb_table_rows(table_id)%}
{%set producto=productos|selectattr('name','eq',name)%}
Productos: {{producto}}
{% endemail_each %}

0 Upvotes
2 Replies 2
dennisedson
Community Manager

Hey @Fernando_Aguila 

I know @kierana has been heads down with HubDB.  He might have some thoughts 😀

Thanks,

Dennis




Check out our Community Developer Blog
where we feature our Community driven developer podcast and how to content
0 Upvotes
kierana
Contributor

As per https://developers.hubspot.com/docs/cms/hubl/filters

 

"Please note that using filters on any personalization variables (such as but not limited to contacts, company, and deal variables) is not currently supported for email in HubSpot due to how emails are rendered. Filters can be applied to these properties on HubSpot CMS page and blog templates."