From 787f38b5c5a85d45208d51b057a853433fa7a589 Mon Sep 17 00:00:00 2001 From: "Tejas (OpenERP)" Date: Thu, 7 Apr 2011 17:22:20 +0530 Subject: [PATCH] FIX : Account Invoice Report, append active and limit 1 with subquery bzr revid: tta@openerp.com-20110407115220-f1qp273vl3gpa6ke --- addons/account/report/account_invoice_report.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/addons/account/report/account_invoice_report.py b/addons/account/report/account_invoice_report.py index 9c7cf014e4d..9e3f6565c24 100644 --- a/addons/account/report/account_invoice_report.py +++ b/addons/account/report/account_invoice_report.py @@ -88,8 +88,8 @@ class account_invoice_report(osv.osv): ai.partner_id as partner_id, ai.payment_term as payment_term, ai.period_id as period_id, - (case when u.uom_type not in ('reference') then - (select name from product_uom where uom_type='reference' and category_id=u.category_id) + (case when (u.uom_type not in ('reference')) then + (select name from product_uom where uom_type='reference' and product_uom.active and category_id=u.category_id limit 1 ) else u.name end) as uom_name,