Email template if condition in odoo

I made some code for the email template. I need to check the amout value if the condition is greater or not, but the ">" sign doesn't work.

My code is here:

  % if object.amount > 12:
       #some code
  % endif

      

I have also tried this.

  % if object.amount &gt 12:
       #some code
  % endif

      

how to apply the ">" operator in an if condition?

+3


source to share


1 answer


Use parentheses around the condition



% if (object.amount > 12):
       #some code
  % endif

      

0


source







All Articles