← Back to team overview

c2c-oerpscenario team mailing list archive

[Bug 801540] Re: Email actions sends outdated data

 

Hello Yann,

Thanks for your reply and good explanation.

Now I have faced the same problem at my end So I am confirming this
issue also I have faced one another issue in trunk only.

@RD Team:

Would you please check the following issue also.

When I have set a email form or email to without "" or '' and then I am
trying to change the state of the helpdesk like open the helpdesk I have
faced the following trace-back on server side.

Traceback (most recent call last):
  File "/home/amp/workspace/trunk6/server/openerp/osv/osv.py", line 118, in wrapper
    return f(self, dbname, *args, **kwargs)
  File "/home/amp/workspace/trunk6/server/openerp/osv/osv.py", line 172, in execute
    res = self.execute_cr(cr, uid, obj, method, *args, **kw)
  File "/home/amp/workspace/trunk6/server/openerp/osv/osv.py", line 163, in execute_cr
    return getattr(object, method)(cr, uid, *args, **kw)
  File "/home/amp/workspace/trunk6/addons/crm/crm.py", line 431, in case_close
    'date_closed': time.strftime('%Y-%m-%d %H:%M:%S'),
  File "/home/amp/workspace/trunk6/addons/base_action_rule/base_action_rule.py", line 187, in make_call_old
    self.pre_action(cr, uid, ids, model, context=context)
  File "/home/amp/workspace/trunk6/addons/base_action_rule/base_action_rule.py", line 165, in pre_action
    self._action(cr, uid, [rule_id], obj.browse(cr, uid, ids, context=context), context=context)
  File "/home/amp/workspace/trunk6/addons/base_action_rule/base_action_rule.py", line 459, in _action
    self.do_action(cr, uid, action, model_obj, obj, context)
  File "/home/amp/workspace/trunk6/addons/crm/crm_action_rule.py", line 105, in do_action
    res = super(base_action_rule, self).do_action(cr, uid, action, model_obj, obj, context=context)
  File "/home/amp/workspace/trunk6/addons/base_action_rule/base_action_rule.py", line 421, in do_action
    emails.append(safe_eval(action.act_email_to, {}, locals_for_emails))
  File "/home/amp/workspace/trunk6/server/openerp/tools/safe_eval.py", line 286, in safe_eval
    return eval(test_expr(expr,_SAFE_OPCODES, mode=mode), globals_dict, locals_dict)
  File "/home/amp/workspace/trunk6/server/openerp/tools/safe_eval.py", line 105, in test_expr
    code_obj = compile(expr, "", mode)
  File "<string>", line 1
     amp@xxxxxxxxxxx
        ^
 SyntaxError: invalid syntax


So would you please also check this issue also as well as above posted issue.

Thanks.


** Changed in: openobject-addons
   Importance: Undecided => Low

** Changed in: openobject-addons
     Assignee: (unassigned) => OpenERP R&D Addons Team 1 (openerp-dev-addons1)

-- 
You received this bug notification because you are a member of C2C
OERPScenario, which is subscribed to the OpenERP Project Group.
https://bugs.launchpad.net/bugs/801540

Title:
  Email actions sends outdated data

Status in OpenERP Modules (addons):
  Confirmed

Bug description:
  With OpenERP 6.0.2 and automated actions from CRM module.

  I planned to automatically send an email after each record changes.
  When i click on "Save" an email is sent with my object data at state "n-1".

  For example with a crm.helpdesk object named "Record number one"
  I change its name property with "Record number two" and click on "Save" then an email is sent, and in this one the [[object]] is always at the "n" state so the [[object.name]] property shows "Record number one".

  It looks like the mail is sent before the database update.

To manage notifications about this bug go to:
https://bugs.launchpad.net/openobject-addons/+bug/801540/+subscriptions


References