Do not offer manual expiry for orders in approval process

This commit is contained in:
Raphael Michel
2023-04-28 18:30:46 +02:00
parent d080e35999
commit 418bfa8b6b

View File

@@ -830,7 +830,7 @@ class Order(LockModel, LoggedModel):
@property
def is_expired_by_time(self):
return (
self.status == Order.STATUS_PENDING and self.expires < now()
self.status == Order.STATUS_PENDING and not self.require_approval and self.expires < now()
and not self.event.settings.get('payment_term_expire_automatically')
)