CMS Development

Octav
Participant

struggling with a dropdown select property

Résolue

Hello, 

 

I'm trying to customize a quote template and i need to check what  values are selected in a dropdown select property but i can´t make it.

 

i have simple if sentence but i can't reach the code inside the if. 

{% if (BUYER_COMPANY.responsabilidades_fiscales).Prueba == true %} 

 

Can some help me, please? 

0 Votes
1 Solution acceptée
SteveHTM
Solution
Guide | Partenaire solutions
Guide | Partenaire solutions

struggling with a dropdown select property

Résolue

@Octav - the proerty values for a dropdown select are stored as string values inside the property. If 'Prueba' is one of the possible selections of the Company property 'responsabilidades_fiscales' then I think the correct HubL test would be:

{% if BUYER_COMPANY.responsabilidades_fiscales == 'Prueba' %}

You could also use the HubL operator string_containing if the property can contain multiple selected dropdown values
(https://developers.hubspot.com/docs/cms/hubl/operators-and-expression-tests#string-containing)

 

I hope this is helpful.

 

Steve

Steve Christian

HTM Solutions

https://info.htmsolutions.biz/meetings/stevec2

mobilePhone
+1 6195183009
emailAddress
stevec@htmsolutions.biz
website
www.htmsolutions.biz
address
San Diego, CA
Create Your Own Free Signature

Voir la solution dans l'envoi d'origine

0 Votes
2 Réponses
SteveHTM
Solution
Guide | Partenaire solutions
Guide | Partenaire solutions

struggling with a dropdown select property

Résolue

@Octav - the proerty values for a dropdown select are stored as string values inside the property. If 'Prueba' is one of the possible selections of the Company property 'responsabilidades_fiscales' then I think the correct HubL test would be:

{% if BUYER_COMPANY.responsabilidades_fiscales == 'Prueba' %}

You could also use the HubL operator string_containing if the property can contain multiple selected dropdown values
(https://developers.hubspot.com/docs/cms/hubl/operators-and-expression-tests#string-containing)

 

I hope this is helpful.

 

Steve

Steve Christian

HTM Solutions

https://info.htmsolutions.biz/meetings/stevec2

mobilePhone
+1 6195183009
emailAddress
stevec@htmsolutions.biz
website
www.htmsolutions.biz
address
San Diego, CA
Create Your Own Free Signature
0 Votes
Octav
Participant

struggling with a dropdown select property

Résolue

@SteveHTM 

 

I made it! Thanks to your explanation and the examples that you gave me.

 

Thank you, so much. 

 

 

0 Votes