openerp-india team mailing list archive
-
openerp-india team
-
Mailing list archive
-
Message #26652
[Bug 1248589] [NEW] Issue in suggested recipient functionality
Public bug reported:
In addons/mail/mail_thread.py/_message_add_suggested_recipient method,
The condition for checking already existing partner ID is not correct.
OpenERP Version 7.0
TEST CASE:
Just for the simulation of this bug , I mentioned this example. In Real-Time, this example situation will never occur.
Create a lead with Customer= Administrator and Salesperson=Administrator. Click on Send a message option for that
document. It will show Administrator (admin@xxxxxxxxxxx) twice in To: Followers of this document as suggested recipient. Make sure that the Administrator is not in the follower list.
CURRENT CODE:
if partner and partner in [val[0] for val in result[obj.id]]:
val[0] --gives--> partner_id. So its needs to be checked with partner.id
instead of partner object.
CORRECTION:
The code should be
if partner and partner.id in [val[0] for val in result[obj.id]]:
Thanks.
** Affects: openobject-addons
Importance: Undecided
Status: New
--
You received this bug notification because you are a member of OpenERP
Indian Team, which is subscribed to OpenERP Addons.
https://bugs.launchpad.net/bugs/1248589
Title:
Issue in suggested recipient functionality
Status in OpenERP Addons (modules):
New
Bug description:
In addons/mail/mail_thread.py/_message_add_suggested_recipient method,
The condition for checking already existing partner ID is not correct.
OpenERP Version 7.0
TEST CASE:
Just for the simulation of this bug , I mentioned this example. In Real-Time, this example situation will never occur.
Create a lead with Customer= Administrator and Salesperson=Administrator. Click on Send a message option for that
document. It will show Administrator (admin@xxxxxxxxxxx) twice in To: Followers of this document as suggested recipient. Make sure that the Administrator is not in the follower list.
CURRENT CODE:
if partner and partner in [val[0] for val in result[obj.id]]:
val[0] --gives--> partner_id. So its needs to be checked with
partner.id instead of partner object.
CORRECTION:
The code should be
if partner and partner.id in [val[0] for val in result[obj.id]]:
Thanks.
To manage notifications about this bug go to:
https://bugs.launchpad.net/openobject-addons/+bug/1248589/+subscriptions
Follow ups
References