Skip to Content
Menu
You need to be registered to interact with the community.
This question has been flagged
2 Odgovori
2434 Prikazi

Hello, I am setting up a mail template.


There are some fields in the form that are sometimes empty and when using the placeholder write this:


FIELD_XXX placeholder: $ {object.field_xxx.name}


Email result

FIELD_XXX = False


I want that if the field $ {object.field_xxx.name} is empty the result is, for example EMPTY


Email result

FIELD_XXX = ""


How can I program it?


Thanks guys!

Avatar
Opusti
Best Answer

Just simply use ${(object.name or '')
Thanks

Avatar
Opusti
Avtor Best Answer

Thanks for your quick response. I put

FIELD_XXX: ${(object.x_studio_field_xxx.name or "")}

and this worked !!!!! THANK YOU VERY MUCH FOR YOUR ANSWER!!!!!

Avatar
Opusti
Related Posts Odgovori Prikazi Aktivnost
4
sep. 23
4666
0
feb. 25
1182
5
nov. 23
8867
1
apr. 24
6354
4
sep. 22
6163