From 0e57dab5224eb13eb8ac6dcd8a13313576ee4f42 Mon Sep 17 00:00:00 2001 From: "rpa (Open ERP)" Date: Tue, 8 Dec 2009 15:21:25 +0530 Subject: [PATCH] [FIX]: crm: Fixed problem in read method when id is blank bzr revid: rpa@tinyerp.com-20091208095125-gi0pf25nrljjiru9 --- addons/crm/crm_calendar.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/addons/crm/crm_calendar.py b/addons/crm/crm_calendar.py index 8854f4c1028..9ce9c43c880 100644 --- a/addons/crm/crm_calendar.py +++ b/addons/crm/crm_calendar.py @@ -311,6 +311,8 @@ class crm_case(osv.osv): ids = map(lambda x:int(str(x).split('-')[0]), ids) res = super(crm_case, self).read(cr, uid, ids, fields=fields, context=context, load=load) read_ids = ",".join([str(x) for x in ids]) + if not read_ids: + return [] cr.execute('select id,rrule,rdates from crm_case where id in (%s)' % read_ids) rrules = filter(lambda x: not x['rrule']==None, cr.dictfetchall()) rdates = []