diff --git a/addons/account/data/invoice_action_data.xml b/addons/account/data/invoice_action_data.xml index e04a3517032..69380567fef 100644 --- a/addons/account/data/invoice_action_data.xml +++ b/addons/account/data/invoice_action_data.xml @@ -7,7 +7,7 @@ Invoice - Send by Email - ${(object.user_id.email or object.company_id.email or 'noreply@localhost')|safe} + ${(object.user_id.email and '%s <%s>' % (object.user_id.name, object.user_id.email) or '')|safe} ${object.company_id.name|safe} Invoice (Ref ${object.number or 'n/a'}) ${object.partner_id.id} diff --git a/addons/portal_sale/portal_sale_data.xml b/addons/portal_sale/portal_sale_data.xml index b8858b00053..97416fd3f15 100644 --- a/addons/portal_sale/portal_sale_data.xml +++ b/addons/portal_sale/portal_sale_data.xml @@ -6,7 +6,7 @@ Sales Order - Send by Email (Portal) - ${(object.user_id.email or '')|safe} + ${(object.user_id.email and '%s <%s>' % (object.user_id.name, object.user_id.email) or '')|safe} ${object.company_id.name|safe} ${object.state in ('draft', 'sent') and 'Quotation' or 'Order'} (Ref ${object.name or 'n/a' }) ${object.partner_invoice_id.id} @@ -89,7 +89,7 @@ Invoice - Send by Email (Portal) - ${(object.user_id.email or object.company_id.email or 'noreply@localhost')|safe} + ${(object.user_id.email and '%s <%s>' % (object.user_id.name, object.user_id.email) or '')|safe} ${object.company_id.name|safe} Invoice (Ref ${object.number or 'n/a' }) ${object.partner_id.id} diff --git a/addons/purchase/data/mail_template_data.xml b/addons/purchase/data/mail_template_data.xml index 1a743871538..52cad8083e3 100644 --- a/addons/purchase/data/mail_template_data.xml +++ b/addons/purchase/data/mail_template_data.xml @@ -5,7 +5,7 @@ RFQ - Send by Email - ${(object.create_uid.email or '')|safe} + ${(object.create_uid.email and '%s <%s>' % (object.create_uid.name, object.create_uid.email) or '')|safe} ${object.company_id.name|safe} Order (Ref ${object.name or 'n/a' }) ${object.partner_id.id} @@ -68,7 +68,7 @@ Purchase Order - Send by Email - ${object.create_uid.email or ''} + ${(object.create_uid.email and '%s <%s>' % (object.create_uid.name, object.create_uid.email) or '')|safe} ${object.company_id.name} Order (Ref ${object.name or 'n/a' }) ${object.partner_id.id} diff --git a/addons/sale/data/mail_template_data.xml b/addons/sale/data/mail_template_data.xml index ee245b26aac..8eb14889c3d 100644 --- a/addons/sale/data/mail_template_data.xml +++ b/addons/sale/data/mail_template_data.xml @@ -5,7 +5,7 @@ Sales Order - Send by Email - ${(object.user_id.email or '')|safe} + ${(object.user_id.email and '%s <%s>' % (object.user_id.name, object.user_id.email) or '')|safe} ${object.company_id.name|safe} ${object.state in ('draft', 'sent') and 'Quotation' or 'Order'} (Ref ${object.name or 'n/a' }) ${object.partner_invoice_id.id} diff --git a/addons/website_quote/data/website_quotation_data.xml b/addons/website_quote/data/website_quotation_data.xml index dd397b7ec3c..4de0cd21482 100644 --- a/addons/website_quote/data/website_quotation_data.xml +++ b/addons/website_quote/data/website_quotation_data.xml @@ -92,7 +92,7 @@ Sales Order - Send by Email (Online Quote) - ${(object.user_id.email or '')|safe} + ${(object.user_id.email and '%s <%s>' % (object.user_id.name, object.user_id.email) or '')|safe} ${object.company_id.name|safe} ${object.state in ('draft', 'sent') and 'Quotation' or 'Order'} (Ref ${object.name or 'n/a' }) ${object.partner_invoice_id.id}