[FIX] base_calendar: access to browse_null attributes
bzr revid: olt@tinyerp.com-20100920113745-o45rgjk2onl4aja5
This commit is contained in:
parent
f691dc9f77
commit
4d96d4657d
|
@ -484,8 +484,12 @@ property or property parameter."),
|
|||
res_obj = att.ref
|
||||
sub = res_obj.name
|
||||
att_infos = []
|
||||
other_invitaion_ids = self.search(cr, uid, [('ref', '=', res_obj._name + ',' + str(res_obj.id))])
|
||||
for att2 in self.browse(cr, uid, other_invitaion_ids):
|
||||
if res_obj:
|
||||
other_invitation_ids = self.search(cr, uid, [('ref', '=', res_obj._name + ',' + str(res_obj.id))])a
|
||||
else:
|
||||
other_invitation_ids = []
|
||||
|
||||
for att2 in self.browse(cr, uid, other_invitation_ids):
|
||||
att_infos.append(((att2.user_id and att2.user_id.name) or \
|
||||
(att2.partner_id and att2.partner_id.name) or \
|
||||
att2.email) + ' - Status: ' + att2.state.title())
|
||||
|
|
|
@ -128,8 +128,9 @@ send an Email to Invited Person')
|
|||
att = att_obj.browse(cr, uid, context_id)
|
||||
att_val.update({
|
||||
'parent_ids': [(4, att.id)],
|
||||
'ref': att.ref._name + ',' +str(att.ref.id)
|
||||
'ref': att.ref and (att.ref._name + ',' +str(att.ref.id)) or False
|
||||
})
|
||||
|
||||
attendees.append(att_obj.create(cr, uid, att_val))
|
||||
if model_field:
|
||||
for attendee in attendees:
|
||||
|
|
Loading…
Reference in New Issue