[FW][FIX] sale: method call over self instead of precise record

Each order does necessarily have the same confirmation template.
And `_get_confirmation_template` is `ensure_one` so it raises when self holds multiple records.

closes odoo/odoo#128743

Forward-port-of: odoo/odoo#128551
Signed-off-by: Victor Feyens (vfe) <vfe@odoo.com>
This commit is contained in:
Horacio Tellez (hote)
2023-07-17 18:13:45 +02:00
parent b43f8c840e
commit 4c484a9822
+1 -1
View File
@@ -928,7 +928,7 @@ class SaleOrder(models.Model):
:return: None
"""
for order in self:
mail_template = self._get_confirmation_template()
mail_template = order._get_confirmation_template()
order._send_order_notification_mail(mail_template)
def _send_payment_succeeded_for_order_mail(self):