Mail Template Language Specific Attachments
This module extends the functionality of mail templates.
It allows you to configure attachments based on the language of the partner or the language configured in the mail template (which is some times different from the partner's language).
- The email template's language could be {{ object.partner_id.lang }} or {{ object.user_id.lang }}, where in the first case we want to send the email in the partner's language and in the second case we want to send the email in the user's language.
For example you can use it to localize your company's terms of agreements.
auto_awesome What this module does
AI-generated from the code · Odoo 18.0Attach different files to an email template depending on the language of the recipient or of the template itself. Configure these language-specific attachments directly on the mail template form.
This module adds a new section called "Language Attachments" to the email template form (the same screen where you normally add attachments to a template). There you choose a "Method" and list one attachment per language.
- Method "Partner Language": the attachment matching the language of the recipient partner is added to the email.
- Method "Template Language": the attachment matching the language used to render the template is added.
For each language you pick a file (only binary attachments can be selected). The list is stored in a new model, ir.attachment.language, which links a template, a language and an attachment. When Odoo prepares the email, it automatically adds the matching language attachment(s) to the message, on top of the normal template attachments.
Access is read-only for regular users and full access for administrators. The module only touches mail.template and the new ir.attachment.language model; it does not change any other business process. It is useful when the same email must carry a different document (for example terms and conditions) depending on the language of the customer or of the email.
Depends on
Models and fields (2)
- mail.template · extends an existing modelir_attachment_language_ids (Language Dependent Attachments), ir_attachment_language_method (Language Attachment Method)
- ir.attachment.language · new modellang (Language), attachment_id (Attachment), mail_template_id (Template)
Text generated by AI (DeepSeek) from reading the Odoo 18.0 code on GitHub; it may contain mistakes, so check the code before deciding. View the code on GitHub
Availability by version
Reviewed: 2026-11-03Confirmation status: 2 confirmed, 7 with no information of 9 versions.
Sources · Odoo 18.0
Confirmed on 2026-11-03 in branch 18.0 of OCA/server-tools.
terminal Installation and usage
OCA documentation · Odoo 18.0Configuration
Source · Odoo 18.0To configure a language dependent attachment:
- Activate the developer mode;
- go to Settings \> Technical \> Email \> Templates;
- go to the form view of the template you want to change;
- choose the Language Attachment Method you want to use;
- change the field Language Dependent Attachments to what you want.
Usage
Source · Odoo 18.0When a template is selected in the mail composer, the attachments will be automatically added based on the recipients language. The language of the recipients can be configured on the Partner form view. When partners with different languages are selected all attachments of the partners languages will be added.
To use the functionality:
- Configure a template (e.g. the sale order mail template)
- go to a sale order;
- click Send by Email;
- the attachments are added based on the email's language or the customer's language (which might not be the same), depending on the configuration of the template.
No verified information in OCA: Installation.
Installation instructions, the distribution package, dependencies and configuration steps are not shown because they have not yet been verified in the module documentation for any version.
Data imported from GitHub: this sheet reflects the latest catalog review, not a live lookup. Always check the module documentation and staging before installing in production.