From 3050e78ee2c83e52fb1aef5ac7199f8007b31657 Mon Sep 17 00:00:00 2001 From: Wolfgang Taferner Date: Fri, 2 Jul 2021 10:05:50 +0000 Subject: [PATCH] [FIX] sale: make sure that bulk invoice creation is not blocked and those orders are skipped instead In case you have installed sale_timesheet and try to do a bulk invoice creation you will be blocked if one order does not have invoiceable lines instead of skipping this specific order. closes odoo/odoo#73261 X-original-commit: 3e03fe467b9fd459223113e477bc31811fbd35ed Signed-off-by: Victor Feyens (vfe) Signed-off-by: Wolfgang Taferner --- addons/sale/models/sale_order.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/addons/sale/models/sale_order.py b/addons/sale/models/sale_order.py index 7cc6575e500..c133b9f8cbf 100644 --- a/addons/sale/models/sale_order.py +++ b/addons/sale/models/sale_order.py @@ -710,7 +710,7 @@ Reason(s) of this behavior could be: invoiceable_lines = order._get_invoiceable_lines(final) if not any(not line.display_type for line in invoiceable_lines): - raise self._nothing_to_invoice_error() + continue invoice_line_vals = [] down_payment_section_added = False