diff --git a/addons/purchase/report/purchase_bill.py b/addons/purchase/report/purchase_bill.py index a16ff44b60c..036309e8e29 100644 --- a/addons/purchase/report/purchase_bill.py +++ b/addons/purchase/report/purchase_bill.py @@ -30,7 +30,7 @@ class PurchaseBillUnion(models.Model): id as vendor_bill_id, NULL as purchase_order_id FROM account_invoice WHERE - type='in_invoice' and state in ('open','in_payment','paid','cancel') + type='in_invoice' and COALESCE(number, '') != '' UNION SELECT -id, name, partner_ref, partner_id, date_order::date as date, amount_untaxed as amount, currency_id, company_id,