Jigar Amin (OpenERP) has proposed merging
lp:~openerp-dev/openobject-server/trunk-bug-920033-jam into
lp:openobject-server.
Requested reviews:
OpenERP Core Team (openerp)
Related bugs:
Bug #920033 in OpenERP Server: "6.1RC1: 'uid' not available in attrs
evaluation context"
https://bugs.launchpad.net/openobject-server/+bug/920033
For more details, see:
https://code.launchpad.net/~openerp-dev/openobject-server/trunk-bug-920033-jam/+merge/103805
The MP Fix the Bug#920033 : 'uid' not available in attrs evaluation context
When we use attrs="{'invisible':[('user_id','=',uid)]}" server not able to
process uid as "uid" dynamic value is not a valid field to be evaluated
client-side. So by Adding UID from client context, rest of the part will be
processed by server.
Web Client Fix is Already Done (As per Comment#2 on Bug)
GTK adding UID fix is in Branch :
lp:~openerp-dev/openobject-client/trunk-bug-920033-jam
and on server while evaling attrs by passing uid via context will fix the issue.
Kindly review this.
Thank You
--
https://code.launchpad.net/~openerp-dev/openobject-server/trunk-bug-920033-jam/+merge/103805
Your team OpenERP R&D Team is subscribed to branch
lp:~openerp-dev/openobject-server/trunk-bug-920033-jam.
=== modified file 'openerp/osv/orm.py'
--- openerp/osv/orm.py 2012-08-14 13:06:56 +0000
+++ openerp/osv/orm.py 2012-08-29 08:58:18 +0000
@@ -96,7 +96,7 @@
# For non-tree views, the context shouldn't be given.
def transfer_node_to_modifiers(node, modifiers, context=None, in_tree_view=False):
if node.get('attrs'):
- modifiers.update(eval(node.get('attrs')))
+ modifiers.update(eval(node.get('attrs'), context))
if node.get('states'):
if 'invisible' in modifiers and isinstance(modifiers['invisible'], list):
_______________________________________________
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