diff --git a/account_banking_payment_export/models/account_payment.py b/account_banking_payment_export/models/account_payment.py index eefebc2ac..8fa3ee257 100644 --- a/account_banking_payment_export/models/account_payment.py +++ b/account_banking_payment_export/models/account_payment.py @@ -137,6 +137,9 @@ class PaymentOrder(models.Model): requested_date = order.date_scheduled or today else: requested_date = today + # No payment date in the past + if requested_date < today: + requested_date = today # Write requested_date on 'date' field of payment line payline.date = requested_date # Group options