تخطي للذهاب إلى المحتوى
القائمة
لقد تم الإبلاغ عن هذا السؤال
2 الردود
2590 أدوات العرض

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!

الصورة الرمزية
إهمال
أفضل إجابة

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

الصورة الرمزية
إهمال
الكاتب أفضل إجابة

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!!!!!

الصورة الرمزية
إهمال
المنشورات ذات الصلة الردود أدوات العرض النشاط
4
سبتمبر 23
5028
0
فبراير 25
1379
5
نوفمبر 23
9183
1
أبريل 24
6569
4
سبتمبر 22
6349