From 5f2a464a8c47b341c102ff2536c24bca3c7f90d1 Mon Sep 17 00:00:00 2001 From: "rpa (Open ERP)" Date: Mon, 9 Aug 2010 19:18:54 +0530 Subject: [PATCH] [FIX]: base_calendar: Corrected wrong interpretation of editing event with recurrence bzr revid: rpa@tinyerp.com-20100809134854-6cu1rm7bsuif3fcn --- addons/base_calendar/base_calendar.py | 9 ++------- 1 file changed, 2 insertions(+), 7 deletions(-) diff --git a/addons/base_calendar/base_calendar.py b/addons/base_calendar/base_calendar.py index 69f048cba71..05f957ce2b0 100644 --- a/addons/base_calendar/base_calendar.py +++ b/addons/base_calendar/base_calendar.py @@ -1212,17 +1212,12 @@ true, it will allow you to hide the event alarm information without removing it. """ event_id = base_calendar_id2real_id(event_id) - datas = self.read(cr, uid, event_id, context=context) defaults.update({ - 'recurrent_uid': base_calendar_id2real_id(datas['id']), - 'recurrent_id': defaults.get('date') or real_date, + 'recurrent_uid': base_calendar_id2real_id(event_id), + 'recurrent_id': real_date, 'rrule_type': 'none', 'rrule': '' }) - exdate = datas['exdate'] and datas['exdate'].split(',') or [] - if real_date and defaults.get('date'): - exdate.append(real_date) - self.write(cr, uid, event_id, {'exdate': ','.join(exdate)}, context=context) new_id = self.copy(cr, uid, event_id, default=defaults, context=context) return new_id