[IMP] default attachment_ids change based on onchange of template_id field.
bzr revid: ysa@tinyerp.com-20110228120440-tpacaidf6371b898
This commit is contained in:
@@ -118,7 +118,9 @@ class email_compose_message(osv.osv_memory):
|
||||
value = email_temp_previ_pool.on_change_ref(cr, uid, [], resource_id, context)
|
||||
vals.update(value.get('value',{}))
|
||||
vals.update({'name': value.get('value',{}).get('subject','')})
|
||||
|
||||
vals.update({'attachment_ids' : email_temp_pool.read(cr, uid, template_id, ['attachment_ids'])['attachment_ids']})
|
||||
else:
|
||||
vals.update({'attachment_ids' : []})
|
||||
return {'value': vals}
|
||||
|
||||
email_compose_message()
|
||||
|
||||
Reference in New Issue
Block a user