[FIX]: base_calendar: Fixed problem in send mail beacuse of ref field

bzr revid: rpa@tinyerp.com-20100318065211-2jt2rzuszi532843
This commit is contained in:
rpa (Open ERP)
2010-03-18 12:22:11 +05:30
parent f47c0ee32b
commit 0cac3f5997
+1 -3
View File
@@ -452,11 +452,9 @@ request was delegated to"),
sign = att.sent_by_uid and att.sent_by_uid.signature or ''
sign = '<br>'.join(sign and sign.split('\n') or [])
res_obj = att.ref
if res_obj and len(res_obj):
res_obj = res_obj[0]
sub = '[%s Invitation][%d] %s' % (company, att.id, res_obj.name)
att_infos = []
other_invitaion_ids = self.search(cr, uid, [('ref','=',att.ref)])
other_invitaion_ids = self.search(cr, uid, [('ref','=', att.ref._name + ',' + str(att.ref.id))])
for att2 in self.browse(cr, uid, other_invitaion_ids):
att_infos.append(((att2.user_id and att2.user_id.name) or \
(att2.partner_id and att2.partner_id.name) or \