Before this commit, the help of the product_email_template module said that the email is sent when the invoice is paid. This is not the case, the current behaviour of the module is that the email is sent when the invoice is validated. Fine-tuning of :4b5265b9b9,10eee18a04and33a413eb29opw-1973946 closes odoo/odoo#33686 Signed-off-by: Jorge Pinna Puissant (jpp) <jpp@odoo.com>
17 lines
711 B
Python
17 lines
711 B
Python
# -*- coding: utf-8 -*-
|
|
|
|
from odoo import fields, models
|
|
|
|
|
|
class ProductTemplate(models.Model):
|
|
""" Product Template inheritance to add an optional email.template to a
|
|
product.template. When validating an invoice, an email will be send to the
|
|
customer based on this template. The customer will receive an email for each
|
|
product linked to an email template. """
|
|
_inherit = "product.template"
|
|
|
|
email_template_id = fields.Many2one('mail.template', string='Product Email Template',
|
|
help='When validating an invoice, an email will be sent to the customer '
|
|
'based on this template. The customer will receive an email for each '
|
|
'product linked to an email template.')
|