From bcb30ec9c070cb47a98de3493a655ad105df8328 Mon Sep 17 00:00:00 2001 From: Mantavya Gajjar Date: Fri, 9 Jul 2010 11:58:01 +0530 Subject: [PATCH] [FIX]: change previous query bzr revid: mga@tinyerp.com-20100709062801-glxmafv6flqdfxuo --- addons/account/wizard/account_invoice_refund.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/addons/account/wizard/account_invoice_refund.py b/addons/account/wizard/account_invoice_refund.py index 4ea58441655..6a19dc988df 100644 --- a/addons/account/wizard/account_invoice_refund.py +++ b/addons/account/wizard/account_invoice_refund.py @@ -78,7 +78,7 @@ class account_invoice_refund(osv.osv_memory): and name = 'company_id'") result_query = cr.fetchone() if result_query: - cr.execute("""select p.id, p.name from account_fiscalyear y, account_period p where y.id=p.fiscalyear_id \ + cr.execute("""select p.id from account_fiscalyear y, account_period p where y.id=p.fiscalyear_id \ and date(%s) between p.date_start AND p.date_stop and y.company_id = %s limit 1""", (date, company.id,)) else: cr.execute("""SELECT id