Community: Framework mailing list archives

RE: Email templates and auto_delete flag inconsistency

Timo Goosen
- 08/05/2014 08:44:44
Can somebody please reconfigure the mass mailing /mailing list software used for this mailing list to include the name of the mailing list
in the title of the message. This is getting very annoying. 

I will even help you configure it if you can't do it yourself.

From: Maxim Litnitskiy []
Sent: 04 August 2014 02:18 PM
To: Community: Framework
Subject: Re: Email templates and auto_delete flag inconsistency

I was mistaken with dependency direction.
mail.mail has a reference to mail.message that means when we delete mail.message that has corresponding mail.mail the latter is also deleted on cascade.
When we delete mail.mail having corresponding mail.message the latter is not deleted on database level.
So the issue is not with ON CASCADE but on general mail.mail delete procedure.
Here is it -

res = super(mail_mail, self).unlink(cr, uid, ids, context=
self.pool.get('mail.message').unlink(cr, uid, parent_msg_ids, context=context)

1. Delete mail.mail
2. Delete mail.message of this mail.
Until second line is removed no lead autoreply will work correctly.

Here is the bug -


    _columns = {
        'mail_message_id': fields.many2one('mail.message', 'Message', required=True, ondelete='cascade'),

Why  delete messages when deleting email?

Post to: