Skip to Content
Menu
This question has been flagged
6 Replies
25582 Views

Hi,

I have been making tests to set up some email templates to contact our clients. These are the addressing settings I am using for one of these templates:

From: ${object-user_id.email}

To (Emails): ${object.email}

To (Partners): ${object.id}

Reply-To:

These are my questions:

  • The e-mail is correctly sent, but the from address when the email is received shows the outgoing email address of the system and not the email of the user. How could I set the From field so that the user's address is shown?
  • I would like to address the potential responses to an email alias (i.e. marketing@mydoamin.com) so that a lead is created when anyone answers the mail. How could I set this alias address (marketing@mydomain.com) in the Reply-to field?

Thank you very much. Regards,

Javier

Avatar
Discard
Best Answer

Hi,

user should have an email given in his account, no need to enter a value in field FROM, see the code :

    'email_from': fields.char('From',
        help="Sender address (placeholders may be used here). If not set, the default "
                "value will be the author's email alias if configured, or email address."),

to have a different address for the reply, give the value address you want in field reply to.

    'reply_to': fields.char('Reply-To', help="Preferred response address (placeholders may be used here)"),

Bye

Avatar
Discard
Author Best Answer

Thank you very much for your response GEM. I am not sure I've understood well the solution your have proposed. Following your comment, this is how I have configured the addressing information of the template:

From: (blank)

To (Emails): ${object.email}

To (Partners): ${object.id}

Reply-To: marketing@mydomain.com

I have sent a sample email using this template as one of the users of the system and this is what I have obtained:

  • Sender address is still the e-mail of the configured outgoing mail address (not the address of the user sending the email)
  • If a try to reply-to the received e-mail, the destination address is the address of the user.

What am I doing wrong?

Thank you for your time. Regards,

Javier

Avatar
Discard
Best Answer

Hello,

In the user's account, an email address should be provided, eliminating the necessity to manually input a value in the "FROM" field. The code snippet provided below demonstrates this functionality:

'email_from': fields.char('From',

help="Sender address (placeholders may be used here). If not set, the default "

"value will be the author's email alias if configured, or email address."),


To specify a different address for the reply, you can utilize the "reply_to" field:


'reply_to': fields.char('Reply-To', help="Preferred response address (placeholders may be used here)"),


By incorporating the "reply_to" field, you can set a specific address where responses should be directed.

Unique value: This approach streamlines the process for the user by automatically fetching their email address from their account, and it also provides the flexibility to set a distinct reply address if needed, enhancing communication efficiency and user experience.


Avatar
Discard
Best Answer

Hi, In fact I have the very opposite issue : when I hit SEND message in CRM app, email in client gmail is receved, but I can see a "from=user email" instead of expected "crm team alias email" 
-A. In email templates I can not find anything related to CRM or this chatter, so I could edit it
I really need to hide user email from customers email, so client will NEVER know user direct email, but RATHER ONLY a SALES TEAM alias email
Where to change it and how?
Thanks

Avatar
Discard
Best Answer

Thanks for this thread. Tell me please, I want to create a template that is available from the drop down when sending a new mail by clicking the envelope icon next to the user name in the top right corner. What is the correct model to add the template to so that it appears in this drop down?

thanks

Avatar
Discard
Best Answer

Any one show is interested and fall o this question, here is how you do it in xml:

<record id="yourdirectory.yourprefered_id" model="mail.template">

<field name="email_from">info@yourcompany.com</field>

  <field name="reply_to">info@yourcompany.com</field>

  <field name="email_to">${object.model_field_representing_email}</field>

  <field name="subject">bla bla bla</field>

...

</record>

Avatar
Discard
Related Posts Replies Views Activity
7
Apr 24
44904
3
Aug 24
20294
3
Sep 15
11278
0
Mar 15
3707
1
Mar 15
5928