[6.0] crm/crm_action_rule - mail action doesn't send mails to user and watchers
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Odoo Addons (MOVED TO GITHUB) |
Fix Released
|
Low
|
OpenERP Publisher's Warranty Team |
Bug Description
Hello,
Method do_action overwrite in crm_action_rule but it doesn't include all email action informations.
Those fields are not considered :
- act_email_to
- act_email_from
- act_mail_to_user
- act_mail_
- act_mail_to_email
and
act_email_cc is added to followers of the model like crm_case, but those followers won't receive the current message if send to followers is checked
The reason is certainly because base_action_rule evolved but crm didn't follow.
Might this function do_action should be reviewed to split the part of modifing object fields and the part of gathering emails ?
---------
And by the way tool tips of automated action seems weird for me maybe there are some extra words. (but I'm not a native english speaker)
Here is an exemple
"Use a python expression to specify the right field on which one than we will use the 'To' field of the header"
I would say
"Specify the 'To' header field. A python expression can be used."
Regards,
Yannick
Related branches
- Naresh(OpenERP) (community): Approve
-
Diff: 17 lines (+3/-3)1 file modifiedcrm/crm_action_rule.py (+3/-3)
description: | updated |
tags: | added: maintenance |
Changed in openobject-addons: | |
assignee: | nobody → OpenERP Publisher's Warranty Team (openerp-opw) |
Changed in openobject-addons: | |
status: | New → Confirmed |
status: | Confirmed → In Progress |
Changed in openobject-addons: | |
status: | Fix Committed → Fix Released |
milestone: | none → 6.0.4 |
About what I said on act_email_cc, I tested it a bit further
It tries to use act_email_cc of the object. (instead of the action ?)
However, the object crm.lead has no attribute act_email_cc.
------- ------- ------- ------- ------- ------- ------- ------- ------- --- action_ rule.py @ line 117 - 124
crm/crm_
If hasattr(obj, 'email_cc') and action. act_email_ cc:
emails = obj.email_ cc.split( ",") action. act_email_ cc)+">" not in emails:
write[ 'email_ cc'] = obj.email_ cc+','+ obj.act_ email_cc
write[ 'email_ cc'] = obj.act_email_cc ------- ------- ------- ------- ------- ------- ------- ------- ---
if '@' in (obj.email_cc or ''):
if obj.act_email_cc not in emails:# and '<'+str(
else:
-------
We check if obj has email_cc but not if it has act_email_cc
So in case of a rule on a crm.lead
I get the following error :
Environment Information : 6.32-37- generic- i686-with- Ubuntu- 10.04-lucid yvaucher/ Projects/ bzr_c2c/ c2c_openerpv6_ migr/trunk/ src/server/ bin/netsvc. py", line 489, in dispatch getService( service_ name).dispatch( method, auth, params) yvaucher/ Projects/ bzr_c2c/ c2c_openerpv6_ migr/trunk/ src/server/ bin/service/ web_services. py", line 599, in dispatch yvaucher/ Projects/ bzr_c2c/ c2c_openerpv6_ migr/trunk/ src/server/ bin/osv/ osv.py" , line 122, in wrapper yvaucher/ Projects/ bzr_c2c/ c2c_openerpv6_ migr/trunk/ src/server/ bin/osv/ osv.py" , line 176, in execute yvaucher/ Projects/ bzr_c2c/ c2c_openerpv6_ migr/trunk/ src/server/ bin/osv/ osv.py" , line 167, in execute_cr yvaucher/ Projects/ bzr_c2c/ c2c_openerpv6_ migr/trunk/ src/server/ bin/addons/ base_action_ rule/base_ action_ rule.py" , line 187, in make_call_old pre_action( cr, uid, ids, model, context=context) yvaucher/ Projects/ bzr_c2c/ c2c_openerpv6_ migr/trunk/ src/server/ bin/addons/ action_ rule_trg_ dates/action_ rule.py" , line 74, in pre_action _action( cr, uid, [rule_id], obj.browse(cr, uid, ids, context=context), context=context) yvaucher/ Projects/ bzr_c2c/ c2c_openerpv6_ migr/trunk/ src/server/ bin/addons/ base_action_ rule/base_ action_ rule.py" , line 469, in _action do_action( cr, uid, action, model_obj, obj, context) yvaucher/ Projects/ bzr_c2c/ c2c_openerpv6_ migr/trunk/ src/server/ bin/addons/ crm/crm_ action_ rule.py" , line 124, in do_action 'email_ cc'] = obj.act_email_cc yvaucher/ Projects/ bzr_c2c/ c2c_openerpv6_ migr/trunk/ src/server/ bin/osv/ ...
System : Linux-2.
OS Name : posix
Distributor ID: Ubuntu
Description: Ubuntu 10.04.3 LTS
Release: 10.04
Codename: lucid
Operating System Release : 2.6.32-37-generic
Operating System Version : #81-Ubuntu SMP Fri Dec 2 20:35:14 UTC 2011
Operating System Architecture : 32bit
Operating System Locale : en_US.UTF8
Python Version : 2.6.5
OpenERP-Client Version : 6.0.3
Last revision No. & ID :Bazaar Package not Found !Traceback (most recent call last):
File "/home/
result = ExportService.
File "/home/
res = fn(db, uid, *params)
File "/home/
return f(self, dbname, *args, **kwargs)
File "/home/
res = self.execute_cr(cr, uid, obj, method, *args, **kw)
File "/home/
return getattr(object, method)(cr, uid, *args, **kw)
File "/home/
self.
File "/home/
self.
File "/home/
self.
File "/home/
write[
File "/home/