From 7e8df5a4b3677ccd7607ca943c9e38e52be4f92e Mon Sep 17 00:00:00 2001 From: Pierre-Yves Dufays Date: Thu, 23 Jun 2022 12:25:14 +0000 Subject: [PATCH] [IMP] account, project, purchase, sale, {test_}mail: improves mail re-usability "mail_notification_paynow" mail template layout has been renamed to "mail_notification_responsible_signature_layout" as it now only differ by the signature. It allows to use it more widely. Task-2801600 Part-of: odoo/odoo#88466 --- addons/account/models/account_move.py | 4 ++-- addons/mail/data/mail_templates_email_layouts.xml | 3 ++- addons/purchase/models/purchase.py | 8 ++++---- addons/sale/models/payment_transaction.py | 2 +- addons/sale/models/res_company.py | 2 +- addons/sale/models/sale_order.py | 6 +++--- addons/test_mail/tests/test_message_post.py | 9 +++++---- addons/website_sale/models/sale_order.py | 2 +- 8 files changed, 19 insertions(+), 17 deletions(-) diff --git a/addons/account/models/account_move.py b/addons/account/models/account_move.py index 0f87d565aae..3f7124fca7a 100644 --- a/addons/account/models/account_move.py +++ b/addons/account/models/account_move.py @@ -3063,7 +3063,7 @@ class AccountMove(models.Model): 'res_model': 'account.invoice.send', 'view_mode': 'form', 'context': { - 'default_email_layout_xmlid': 'mail.mail_notification_paynow', + 'default_email_layout_xmlid': 'mail.mail_notification_layout_with_responsible_signature', 'default_template_id': self.env.ref(self._get_mail_template()).id, 'mark_invoice_as_sent': True, 'active_model': 'account.move', @@ -3099,7 +3099,7 @@ class AccountMove(models.Model): default_template_id=template and template.id or False, default_composition_mode='comment', mark_invoice_as_sent=True, - default_email_layout_xmlid="mail.mail_notification_paynow", + default_email_layout_xmlid="mail.mail_notification_layout_with_responsible_signature", model_description=self.with_context(lang=lang).type_name, force_email=True, ) diff --git a/addons/mail/data/mail_templates_email_layouts.xml b/addons/mail/data/mail_templates_email_layouts.xml index 859ab2c84e7..32d5825c189 100644 --- a/addons/mail/data/mail_templates_email_layouts.xml +++ b/addons/mail/data/mail_templates_email_layouts.xml @@ -287,7 +287,8 @@ -