You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

23 lines
791 B

  1. # Copyright 2016 Antonio Espinosa - <antonio.espinosa@tecnativa.com>
  2. # Copyright 2017 Vicent Cubells - <vicent.cubells@tecnativa.com>
  3. # License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).
  4. from odoo import models, api
  5. class MailMail(models.Model):
  6. _inherit = "mail.mail"
  7. @api.model
  8. def _tracking_email_prepare(self, partner, email):
  9. res = super(MailMail, self)._tracking_email_prepare(partner, email)
  10. res['mail_id_int'] = self.id
  11. res['mass_mailing_id'] = self.mailing_id.id
  12. res['mail_stats_id'] = self.statistics_ids[:1].id \
  13. if self.statistics_ids else False
  14. return res
  15. @api.model
  16. def _get_tracking_url(self):
  17. # Invalid this tracking image, we have other to do the same
  18. return False