From d389789fdc5f2195db4fc1192fbb13b21fe35a24 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Adri=C3=A0=20Tarroja=20Caubet?= Date: Thu, 10 Sep 2026 08:20:15 +0200 Subject: [PATCH] Check for running deferrals when closing a standard period only Invoice deferred creates moves only on standard period Closes #15042 (grafted from f56a0a6d5558009b138069bdad1c3d7ff9c37c87) --HG-- branch : 7.0 --- modules/account_invoice_defer/account.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/modules/account_invoice_defer/account.py b/modules/account_invoice_defer/account.py index dc7121ca98..261c35cfeb 100644 --- a/modules/account_invoice_defer/account.py +++ b/modules/account_invoice_defer/account.py @@ -420,7 +420,9 @@ class Period(metaclass=PoolMeta): @classmethod def close(cls, periods): for period in periods: - period.check_invoice_deferred_running() + if period.type == 'standard': + # Invoice deferred creates moves only on standard period + period.check_invoice_deferred_running() super().close(periods) def check_invoice_deferred_running(self):