Odooers论坛

欢迎!

该社区面向专业人士和我们产品和服务的爱好者。
分享和讨论最好的内容和新的营销理念,建立您的专业形象,一起成为更好的营销人员。


0

How can I change the FROM and REPLY-TO email address of all my helpdesk emails going out? Instead of the user who replies?

形象
odoo
2 注释
形象
丢弃
形象
odoo
-

Thanks, helped.

形象
odoo
-

Thank you for your tip. Worked like a charm.

3 答案
0
形象
odoo
最佳答案

You can create an Automated Action that catches the emails just before they are sent and changes the address, just for helpdesk tickets:


if record.model == 'helpdesk.ticket':
    record['email_from'] = 'helpdesk@odoo.com'
    record['reply_to'] = 'helpdesk@odoo.com'
1 备注
形象
丢弃
形象
odoo
-

In Odoo 13.0 (did not check other versions) you have to link the action to the Message object and adapt the code as well:

log("Action called for %d records" % len(records))

for mail in records:

log("action called for model %s" % mail.model)

if mail.model != "sale.order":

continue

mail.write({

"email_from": "demo_sales@therp.nl",

"reply_to": "demo_sales@therp.nl",

})

0
形象
odoo
最佳答案

Hey, that's a really good solution :) What if you have several "helpdesk teams"? For example, I have a team for support. Then I want the mail to go out from support@odoo.com. 

And then I have another team for Customer Care - I would like the mail to go out as customercare@odoo.com. 

Could you possibly help me with this? 

形象
丢弃
0
形象
odoo
最佳答案

Hi, sorry to hijack the thread but i have a similiar problem with Survey module.

The email_from get correctly changed by the action, but the reply_to no, it remain the address of my odoo user. Any hint?

I've adjuster the code to be:

if record.model == 'survey.survey':
    record['email_from'] = 'info@odoo.com'
    record['reply_to'] = 'info@odoo.com'
形象
丢弃