Browse Source

[IMP] send mail using sudo()

pull/9/head
houssine 6 years ago
parent
commit
48d58595ed
  1. 2
      easy_my_coop/models/account_invoice.py

2
easy_my_coop/models/account_invoice.py

@ -119,7 +119,7 @@ class account_invoice(models.Model):
certificate_email_template = line.product_id.mail_template
# we send the email with the certificate in attachment
certificate_email_template.send_mail(self.partner_id.id, False)
certificate_email_template.sudo().send_mail(self.partner_id.id, False)
if self.company_id.create_user:
self.create_user(self.partner_id)

Loading…
Cancel
Save