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 16.0Lets you attach different files to an email template depending on the language, so customers receive documents in their own language.
This module adds language-specific attachments to email templates. On any email template form, a new "Language Attachments" section appears right after the standard attachments field. There you choose a Method and build a list of rows, each pairing a language with a file.
- 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 the template is rendered in is added.
The list is only shown when a method is selected. Only binary files can be chosen as attachments. When Odoo prepares an email from the template, it automatically adds the matching file(s) to the message, without duplicating the same file twice.
The module touches the email template model mail.template and introduces a new model ir.attachment.language that stores the language/file pairs. Access is read-only for all users and full management for administrators. It depends on the standard Mail app.
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 16.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: 1 confirmed, 8 with no information of 9 versions.
Sources · Odoo 16.0
Confirmed on 2026-11-03 in branch 16.0 of OCA/server-tools.
terminal Installation and usage
OCA documentation · Odoo 16.0Configuration
Source · Odoo 16.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 16.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.