Do not allow to generate invoice for expired or canceled order

This commit is contained in:
Raphael Michel
2023-06-13 15:56:01 +02:00
parent 41f5ca3f9d
commit a2f3dcce02

View File

@@ -722,6 +722,8 @@ def can_generate_invoice(event, order, ignore_payments=False):
)
) and (
invoice_qualified(order)
) and (
order.status in (Order.STATUS_PENDING, Order.STATUS_PAID)
)
)
if not ignore_payments: