EMail模板

我们都知道写出一封好的电子邮件对于获得高响应率至关重要,但是您不想每次都重写相同的结构,对吗? 这就是电子邮件模板的用武之地。无需每次都重写整个电子邮件结构,您可以节省时间专注于内容。 多个模板还使您可以向正确的受众传递正确的消息,从而改善他们在公司的整体体验。

注解

The email templates use QWeb. The composer allows you to edit emails in their final rendering, making customizations more robust as you don’t have to edit code.

Defining a default reply to on your mail template

Although the field reply to is available within the mail templates, this field is only used for mass mailing mode (this means when sending templates on what we call bulk emailing). You can send emails in bulk in almost every app that has a list view. Select the records you want and click on the action button. If you have an option to send an email, you will see a mail composer with possible values to define:

Composer in mass mailing mode after selecting multiple quotations.

You can also define them by default on the template:

Reply-to field on template.

Because of this, setting a value in this field is useless as the value defined will be totally ignored. The default reply-to value is the default catchall email address to ensure a communication between your customer and your Odoo database. For more information about the way the catchall works, please check how to manage inbound messages.

Transactional emails and corresponding URL for each company

When using Odoo, multiple events trigger the sending of automated emails. These emails are known as transactional emails and sometimes contain links pointing to your Odoo database.

By default, links generated by the database use the dynamic web.base.url key defined in the system parameters. More information about this parameter.

If the website application isn’t installed, the web.base.url key will always be the default parameter used to generate all the links.

It’s important to know that this key can only have a single value, meaning that in a multi-website/company database environment, even if you have a specific domain name for each website, the links generated to share a document or within a transactional email might remain the same, whatever the website/company related to the sending of the email/document.

This is not always the case as some Odoo applications have a link established in the database with the website application, meaning that in this case, if a specific domain is defined for the websites, the URL generated in the email template will use the domain defined on the corresponding website of the company.

警告

A document shared using the documents application will always use the web.base.url key, as the document shared isn’t associated with any particular website. Meaning that the URL will always be the same (the web.base.url key value), whatever the company it’s shared from, this is a known limitation!

On the other hand, sales orders made by a customer on one of your Odoo e-commerce websites have a link established with the website from which the order was made. As a result, the e-mail sent for the sales orders uses the domain name defined for the corresponding website to generate the links.

For more information about how to configure your domains, we invite you to check our domain name documentation.

Updating translations within email templates

Email templates are automatically translated. Changing the translations shouldn’t be necessary. However, if for a specific reason you’d like to change some of the translations, this can be done.

Like any modification in the code, keep in mind that modifications that aren’t done correctly (for example modifications leading to bad syntax) can break the template, as a result, the template will appear blank.

In order to edit your translations, follow these steps from the template.

  1. Click on the edit button, then on the language button

    Edit the language of a template
  2. A pop-up window with the different languages installed on the database will be displayed. From here, editing the translations will be possible. Don’t forget to hit the save button to preserve your changes.

    Translation of the body of the Application template in the different languages installed.