openerp-dev-web team mailing list archive
-
openerp-dev-web team
-
Mailing list archive
-
Message #03631
[Merge] lp:~openerp-dev/openobject-addons/trunk-bug-722723-atp into lp:openobject-addons
Atul Patel(OpenERP) has proposed merging lp:~openerp-dev/openobject-addons/trunk-bug-722723-atp into lp:openobject-addons.
Requested reviews:
tfr (Openerp) (tfr)
Related bugs:
#722723 [6.0] crm - send reminder uses wrong "from" email
https://bugs.launchpad.net/bugs/722723
For more details, see:
https://code.launchpad.net/~openerp-dev/openobject-addons/trunk-bug-722723-atp/+merge/51874
Hello ,
I have fixed suggested Improvements.
Kindly review this.
Thanks
--
https://code.launchpad.net/~openerp-dev/openobject-addons/trunk-bug-722723-atp/+merge/51874
Your team OpenERP R&D Team is subscribed to branch lp:~openerp-dev/openobject-addons/trunk-bug-722723-atp.
=== modified file 'crm/crm.py'
--- crm/crm.py 2011-03-01 12:50:42 +0000
+++ crm/crm.py 2011-03-02 10:35:30 +0000
@@ -440,6 +440,7 @@
@param context: A standard dictionary for contextual values
"""
+
return self.remind_user(cr, uid, ids, context, attach,
destination=False)
@@ -450,20 +451,27 @@
@param uid: the current userâs ID for security checks,
@param ids: List of Remind user's IDs
@param context: A standard dictionary for contextual values
-
"""
for case in self.browse(cr, uid, ids, context=context):
if not case.section_id.reply_to:
raise osv.except_osv(_('Error!'), ("Reply To is not specified in the sales team"))
if not case.email_from:
raise osv.except_osv(_('Error!'), ("Partner Email is not specified in Case"))
- if case.section_id.reply_to and case.email_from:
- src = case.email_from
+ if not case.user_id.user_email:
+ raise osv.except_osv(_('Error!'), ("User Email is not specified in Case"))
+ if case.section_id.user_id:
+ case_email = case.section_id.user_id.user_email
+ else:
+ case_email = case.user_id.user_email
+
+ if case.section_id.reply_to and case_email:
+ src = case_email
dest = case.section_id.reply_to
body = case.description or ""
if case.message_ids:
body = case.message_ids[0].description or ""
if not destination:
+ src = case.email_from
src, dest = dest, src
if body and case.user_id.signature:
if body:
Follow ups