Struggling with Programmable Email Beta - Conditional Logic
SOLVE
I have signed up for the Programmable Email Beta and wanting to create an email that checks a contact property (contact.sessions_registered_2021) and displays a certain table row depending on what values it holds. The property is a multiple select property with options being (Session 1, Session 2, Session 3).
I've added a sample of what I've got below so far below, but I cannot get it to work. I'm not a developer and there is limited documentation on this as it's still in Beta, Hubspot support has been a bit slow as well, so hoping someone in the community might be able to help me.
Struggling with Programmable Email Beta - Conditional Logic
SOLVE
Hi Indra,
I'm afraid this doesn't solve the issue as the property is a multiple select, so I need to use the 'containing' expression.
However, I have found the solution to the problem now thanks to Hubspot support. I wasn't actually accessing the value when writing the statement. So instead of:
{% if contact.sessions_registered_2021 is containing 'Session 1' %}
it should be:
{% if contact.sessions_registered_2021.value is containing 'Session 1' %}
Thanks to Hubspot support for looking into this for me. I imagine this will become a lot more clear in the documentation once the product is out of beta.
Struggling with Programmable Email Beta - Conditional Logic
SOLVE
Hi Indra,
I'm afraid this doesn't solve the issue as the property is a multiple select, so I need to use the 'containing' expression.
However, I have found the solution to the problem now thanks to Hubspot support. I wasn't actually accessing the value when writing the statement. So instead of:
{% if contact.sessions_registered_2021 is containing 'Session 1' %}
it should be:
{% if contact.sessions_registered_2021.value is containing 'Session 1' %}
Thanks to Hubspot support for looking into this for me. I imagine this will become a lot more clear in the documentation once the product is out of beta.