From a230fb4d6b0dd9bbc204bdeaa854d29515bb3fd5 Mon Sep 17 00:00:00 2001 From: baje-odoo Date: Tue, 1 Jul 2025 15:11:44 +0200 Subject: [PATCH] [FIX] account: hide due date on cancelled invoices and vendor bills Purpose ------- This hides the Due Date field on invoices when the document has been cancelled. Once an invoice is cancelled, no payment is expected anymore, so the due date becomes irrelevant and potentially misleading. Changes ------- - Added condition on the `invoice_date_due` field in the invoice form view. - The field is now hidden when the invoice state is `cancel`. How to test ----------- 1. Go to the Accounting app. 2. Create a Customer Invoice or Vendor Bill with a due date. 3. Validate it, then cancel the invoice. 4. Open the cancelled the list view, the due date should be empty for the cancelled lines. --- addons/account/views/account_move_views.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/addons/account/views/account_move_views.xml b/addons/account/views/account_move_views.xml index 5ed5e8aa6eaeb..69ea637170569 100644 --- a/addons/account/views/account_move_views.xml +++ b/addons/account/views/account_move_views.xml @@ -522,7 +522,7 @@ - +