Skip to main content

Filter mail templates by domain on the active record

Project description

Odoo Community Association

Mail Template Domain

Beta License: AGPL-3 OCA/mail Translate me on Weblate Try me on Runboat

This module allows setting an application domain on mail templates.

When a domain is configured on a template, that template will only appear in the email composer when the active record matches the domain. Templates without a domain continue to appear for all records of the applicable model.

Table of contents

Usage

To use this module:

  1. Go to Settings > Technical > Email > Templates.

  2. Open or create a mail template.

  3. Select an option under Applies to (such as Contact).

  4. Check the Restrict to checkbox, set the domain that records must match for this template to appear in the composer (e.g. [('is_company', '=', True)] to show the template only on contacts where Is a Company is set).

  5. Leave Apply on empty to keep the template available for all records of the model (default behaviour).

When a user opens the email composer from a record, only templates whose Apply on domain matches that record will be listed in the Load template dropdown.

Known issues / Roadmap

The domain applied automatically in server actions is not supported.

Bug Tracker

Bugs are tracked on GitHub Issues. In case of trouble, please check there if your issue has already been reported. If you spotted it first, help us to smash it by providing a detailed and welcomed feedback.

Do not contact contributors directly about support or help with technical issues.

Credits

Authors

  • Tecnativa

Contributors

  • Tecnativa:

    • Cristina Hidalgo

    • Víctor Martínez

Maintainers

This module is maintained by the OCA.

Odoo Community Association

OCA, or the Odoo Community Association, is a nonprofit organization whose mission is to support the collaborative development of Odoo features and promote its widespread use.

This module is part of the OCA/mail project on GitHub.

You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distributions

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

File details

Details for the file odoo_addon_mail_template_domain-18.0.1.0.0.2-py3-none-any.whl.

File metadata

File hashes

Hashes for odoo_addon_mail_template_domain-18.0.1.0.0.2-py3-none-any.whl
Algorithm Hash digest
SHA256 5e3f8c8052ad6d498671d26777744ac4a6693ca7a6cf04f266e8f89797ef122c
MD5 dc8a5590cd06c73fb54652d983aee705
BLAKE2b-256 6b7dc6cd44cf29324adf353dfc6ce01653c8bf3ac6f183594e66f183cb9ed66e

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page