From 5548208de0a5d85e8054031e04dda19ea12c17e2 Mon Sep 17 00:00:00 2001 From: "Pedro M. Baeza" Date: Tue, 27 Dec 2022 15:43:19 +0100 Subject: [PATCH] [FIX] contract: Put proper invoice accounting date Steps to reproduce the problem - Create a new contract with starting date 2023-01-01. - Run the advance invoicing wizard on 2022-12-27. Current behavior: The invoice has as invoice date (invoice_date) 2023-01-01, but accounting date (date) 2022-12-27. Expected behavior: To have the same accounting date than the invoice date. If not, things like the new fiscal year numbering won't work correctly. TT40964 --- contract/models/contract.py | 1 + 1 file changed, 1 insertion(+) diff --git a/contract/models/contract.py b/contract/models/contract.py index f283e3332..de67a3ce9 100644 --- a/contract/models/contract.py +++ b/contract/models/contract.py @@ -445,6 +445,7 @@ class ContractContract(models.Model): "company_id": self.company_id.id, "currency_id": self.currency_id.id, "invoice_date": date_invoice, + "date": date_invoice, "journal_id": journal.id, "invoice_origin": self.name, }