Devishree Brahmbhatt (OpenERP) has proposed merging
lp:~openerp-dev/openobject-addons/trunk-warning-dbr into lp:openobject-addons.
Requested reviews:
OpenERP R&D Team (openerp-dev)
For more details, see:
https://code.launchpad.net/~openerp-dev/openobject-addons/trunk-warning-dbr/+merge/113686
Hello,
Remove main user_id related warning.
Thanks,
DBR
--
https://code.launchpad.net/~openerp-dev/openobject-addons/trunk-warning-dbr/+merge/113686
Your team OpenERP R&D Team is requested to review the proposed merge of
lp:~openerp-dev/openobject-addons/trunk-warning-dbr into lp:openobject-addons.
=== modified file 'l10n_uk/demo/demo.xml'
--- l10n_uk/demo/demo.xml 2012-03-22 10:34:50 +0000
+++ l10n_uk/demo/demo.xml 2012-07-06 05:04:25 +0000
@@ -1,6 +1,6 @@
<openerp>
<data noupdate="1">
- <record id="smartmode" model="res.partner">
+ <record id="smartmode1" model="res.partner">
<field name="comment">UK OpenERP Partner</field>
<field name="ref">smartmode</field>
<field name="website">http://www.smartmode.co.uk</field>
@@ -12,7 +12,7 @@
<field name="name">Vadim Chobanu</field>
<field name="zip">HA4 7JW</field>
<field name="city">Ruislip</field>
- <field name="partner_id" ref="smartmode"/>
+ <field name="parent_id" ref="smartmode1"/>
<field name="country_id" model="res.country" search="[('code','=','uk')]"/>
<field name="email">[email protected]</field>
<field name="phone">+44 (0) 8456434548</field>
=== modified file 'mail/mail_thread.py'
--- mail/mail_thread.py 2012-07-02 16:13:23 +0000
+++ mail/mail_thread.py 2012-07-06 05:04:25 +0000
@@ -202,7 +202,6 @@
def message_create_get_notification_user_ids(self, cr, uid, thread_ids, new_msg_vals, context=None):
if context is None:
context = {}
-
notif_user_ids = []
body = new_msg_vals.get('body_html', '') if new_msg_vals.get('subtype', 'plain') == 'html' else new_msg_vals.get('body_text', '')
for thread_id in thread_ids:
@@ -880,7 +879,7 @@
""" When creating a new message, set as unread if uid is not the
object responsible. """
for obj in self.browse(cr, uid, ids, context=context):
- if obj.message_state and hasattr(obj, 'user_id') and (not obj.user_id or obj.user_id.id != uid):
+ if obj.message_state and ('user_id' in obj._columns.keys()) and (not obj.user_id or obj.user_id.id != uid) :
self.message_mark_as_unread(cr, uid, [obj.id], context=context)
def message_check_and_set_unread(self, cr, uid, ids, context=None):
_______________________________________________
Mailing list: https://launchpad.net/~openerp-dev-gtk
Post to : [email protected]
Unsubscribe : https://launchpad.net/~openerp-dev-gtk
More help : https://help.launchpad.net/ListHelp