[Erp5-report] r25758 - /erp5/trunk/products/ERP5Type/Accessor/Base.py
nobody at svn.erp5.org
nobody at svn.erp5.org
Mon Mar 2 05:02:57 CET 2009
Author: yusei
Date: Mon Mar 2 05:02:56 2009
New Revision: 25758
URL: http://svn.erp5.org?rev=25758&view=rev
Log:
An attribute named "MethodName__roles__" should not be acquired from parents.
Modified:
erp5/trunk/products/ERP5Type/Accessor/Base.py
Modified: erp5/trunk/products/ERP5Type/Accessor/Base.py
URL: http://svn.erp5.org/erp5/trunk/products/ERP5Type/Accessor/Base.py?rev=25758&r1=25757&r2=25758&view=diff
==============================================================================
--- erp5/trunk/products/ERP5Type/Accessor/Base.py [utf8] (original)
+++ erp5/trunk/products/ERP5Type/Accessor/Base.py [utf8] Mon Mar 2 05:02:56 2009
@@ -204,7 +204,7 @@
class __roles__:
@staticmethod
def rolesForPermissionOn(ob):
- roles = getattr(ob.im_self, '%s__roles__' % ob.__name__, None)
+ roles = getattr(aq_base(ob.im_self), '%s__roles__' % ob.__name__, None)
if roles is None:
return rolesForPermissionOn(None, ob.im_self, ('Manager',),
'_Modify_portal_content_Permission')
@@ -215,7 +215,7 @@
class __roles__:
@staticmethod
def rolesForPermissionOn(ob):
- roles = getattr(ob.im_self, '%s__roles__' % ob.__name__, None)
+ roles = getattr(aq_base(ob.im_self), '%s__roles__' % ob.__name__, None)
if roles is None:
return rolesForPermissionOn(None, ob.im_self, ('Manager',),
'_Access_contents_information_Permission')
More information about the Erp5-report
mailing list