| REPOSITORY | |
|---|---|
| REPOSITORY | OCA/server-tools |
| GIT | |
| GIT | https://github.com/OCA/server-tools.git |
| GIT FOLDER | |
| GIT FOLDER | https://github.com/OCA/server-tools/tree/18.0/mail_template_attachment_per_lang |
| VERSION | |
| VERSION | 1.0.0 |
| CATEGORY | |
| CATEGORY | Localization |
| LICENSE | |
| LICENSE | AGPL-3 |
| APPLICATION | |
| APPLICATION | No |
| AUTO-INSTALLABLE | |
| AUTO-INSTALLABLE | No |
| AUTHORS | |
| AUTHORS | Odoo Community Association (OCA), Onestein |
| MAINTAINERS | |
| MAINTAINERS | Odoo Community Association (OCA), Onestein |
| COMMITTERS | |
| COMMITTERS | OCA-git-bot, oca-ci, LauraCForgeFlow |
| WEBSITE | |
| WEBSITE | https://github.com/OCA/server-tools |
| LAST TRACKING UPDATE | |
| LAST TRACKING UPDATE | 2026-07-06 19:30:08 |
| ODOO DEPENDENCIES | |
| ODOO DEPENDENCIES |
odoo/odoo: - base - base_setup - web - bus - web_tour - html_editor |
| PYTHON DEPENDENCIES | |
| PYTHON DEPENDENCIES | Not have |
| SYSTEM DEPENDENCIES | |
| SYSTEM DEPENDENCIES | Not have |
| DESCRIPTION | |
| DESCRIPTION | 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. |
| XML ID | Name | Model | Type | Status |
|---|---|---|---|---|
mail_template_form |
mail.template.form | mail.template | xpath | Inherits mail.email_template_form |
attachment_id
Many2one → ir.attachment
comodel_name='ir.attachment'
ondelete='cascade'
required=True
string='Attachment'
lang
Selection
required=True
selection=<expr>
string='Language'
mail_template_id
Many2one → mail.template
comodel_name='mail.template'
ondelete='cascade'
required=True
string='Template'
No public methods.
ir_attachment_language_ids
One2many → ir.attachment.language
comodel_name='ir.attachment.language'
inverse_name='mail_template_id'
string='Language Dependent Attachments'
ir_attachment_language_method
Selection
default='partner_lang'
selection=[('partner_lang', 'Partner Language'), ('template_lang', 'Template Language')]
string='Language Attachment Method'
No public methods.
| REPOSITORY | |
|---|---|
| REPOSITORY | OCA/server-tools |
| GIT | |
| GIT | https://github.com/OCA/server-tools.git |
| GIT FOLDER | |
| GIT FOLDER | https://github.com/OCA/server-tools/tree/17.0/mail_template_attachment_per_lang |
| VERSION | |
| VERSION | 1.0.0 |
| CATEGORY | |
| CATEGORY | Localization |
| LICENSE | |
| LICENSE | AGPL-3 |
| APPLICATION | |
| APPLICATION | No |
| AUTO-INSTALLABLE | |
| AUTO-INSTALLABLE | No |
| AUTHORS | |
| AUTHORS | Odoo Community Association (OCA), Onestein |
| MAINTAINERS | |
| MAINTAINERS | Odoo Community Association (OCA), Onestein |
| COMMITTERS | |
| COMMITTERS | OCA-git-bot, oca-ci, LauraCForgeFlow |
| WEBSITE | |
| WEBSITE | https://github.com/OCA/server-tools |
| LAST TRACKING UPDATE | |
| LAST TRACKING UPDATE | 2026-07-06 19:20:01 |
| ODOO DEPENDENCIES | |
| ODOO DEPENDENCIES |
odoo/odoo: - base - base_setup - web - bus - web_tour |
| PYTHON DEPENDENCIES | |
| PYTHON DEPENDENCIES | Not have |
| SYSTEM DEPENDENCIES | |
| SYSTEM DEPENDENCIES | Not have |
| DESCRIPTION | |
| DESCRIPTION | 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. |
| XML ID | Name | Model | Type | Status |
|---|---|---|---|---|
mail_template_form |
mail.template.form | mail.template | xpath | Inherits mail.email_template_form |
attachment_id
Many2one → ir.attachment
comodel_name='ir.attachment'
ondelete='cascade'
required=True
string='Attachment'
lang
Selection
required=True
selection=<expr>
string='Language'
mail_template_id
Many2one → mail.template
comodel_name='mail.template'
ondelete='cascade'
required=True
string='Template'
No public methods.
ir_attachment_language_ids
One2many → ir.attachment.language
comodel_name='ir.attachment.language'
inverse_name='mail_template_id'
string='Language Dependent Attachments'
ir_attachment_language_method
Selection
default='partner_lang'
selection=[('partner_lang', 'Partner Language'), ('template_lang', 'Template Language')]
string='Language Attachment Method'
No public methods.