[FIX] Move old uniq constraint of google_id from crm_meeting to calendar.attendee

bzr revid: jke@openerp.com-20131213172500-nclgwxrldbf9nyxu
This commit is contained in:
jke-openerp 2013-12-13 18:25:00 +01:00
parent c4dfc941e6
commit 04182723fa
2 changed files with 3 additions and 1 deletions

View File

@ -710,7 +710,7 @@ class crm_meeting(osv.osv):
_columns = {
'oe_update_date': fields.datetime('OpenERP Update Date'),
}
_sql_constraints = [('google_id_uniq','unique(google_internal_event_id)', 'Google ID must be unique!')]
# If attendees are updated, we need to specify that next synchro need an action
class calendar_attendee(osv.osv):
_inherit = 'calendar.attendee'
@ -720,6 +720,8 @@ class calendar_attendee(osv.osv):
'oe_synchro_date': fields.datetime('OpenERP Synchro Date'),
}
_sql_constraints = [('google_id_uniq','unique(google_internal_event_id)', 'Google ID must be unique!')]
def write(self, cr, uid, ids, vals, context=None):
if context is None:
context = {}