chore: check if discount_percentage exists
fixes TypeError: '>' not supported between instances of 'NoneType' and 'float' Signed-off-by: Chinmay D. Pai <chinmaydpai@gmail.com>
This commit is contained in:
parent
2caf32d421
commit
01aca675ef
@ -19,7 +19,7 @@
|
||||
{%- endmacro %}
|
||||
|
||||
{%- macro render_discount_or_margin(item) -%}
|
||||
{%- if item.discount_percentage > 0.0 or item.margin_type %}
|
||||
{%- if (item.discount_percentage and item.discount_percentage > 0.0) or item.margin_type %}
|
||||
<ScontoMaggiorazione>
|
||||
{%- if item.discount_percentage > 0.0 %}
|
||||
<Tipo>SC</Tipo>
|
||||
|
Loading…
Reference in New Issue
Block a user