Commit d8e5499f authored by Romain Courteaud's avatar Romain Courteaud

updateLocalRolesOnSecurityGroups needs to be unrestricted on ERP5Type instead

of Base.


git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@19071 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent df287826
...@@ -3109,10 +3109,6 @@ class Base( CopyContainer, ...@@ -3109,10 +3109,6 @@ class Base( CopyContainer,
"""Assign Local Roles to Groups on self, based on Portal Type Role """Assign Local Roles to Groups on self, based on Portal Type Role
Definitions and "ERP5 Role Definition" objects contained inside self. Definitions and "ERP5 Role Definition" objects contained inside self.
""" """
updateLocalRolesOnSecurityGroups = UnrestrictedMethod(self._updateLocalRolesOnSecurityGroups)
return updateLocalRolesOnSecurityGroups(**kw)
def _updateLocalRolesOnSecurityGroups(self, **kw):
self._getTypesTool().getTypeInfo(self)\ self._getTypesTool().getTypeInfo(self)\
.updateLocalRolesOnSecurityGroups(self, **kw) .updateLocalRolesOnSecurityGroups(self, **kw)
......
...@@ -39,6 +39,7 @@ from Products.CMFCore.utils import _checkPermission ...@@ -39,6 +39,7 @@ from Products.CMFCore.utils import _checkPermission
from Products.ERP5Type import PropertySheet from Products.ERP5Type import PropertySheet
from Products.ERP5Type import _dtmldir from Products.ERP5Type import _dtmldir
from Products.ERP5Type import Permissions from Products.ERP5Type import Permissions
from Products.ERP5Type.UnrestrictedMethod import UnrestrictedMethod
# Security uses ERP5Security by default # Security uses ERP5Security by default
try: try:
...@@ -450,7 +451,12 @@ class ERP5TypeInformation( FactoryTypeInformation, ...@@ -450,7 +451,12 @@ class ERP5TypeInformation( FactoryTypeInformation,
return factory_method(portal, id).propertyMap() return factory_method(portal, id).propertyMap()
security.declarePrivate('updateLocalRolesOnSecurityGroups') security.declarePrivate('updateLocalRolesOnSecurityGroups')
def updateLocalRolesOnSecurityGroups(self, ob, user_name=None, def updateLocalRolesOnSecurityGroups(self, *args, **kw):
updateLocalRolesOnSecurityGroups = \
UnrestrictedMethod(self._updateLocalRolesOnSecurityGroups)
return updateLocalRolesOnSecurityGroups(*args, **kw)
def _updateLocalRolesOnSecurityGroups(self, ob, user_name=None,
reindex=True): reindex=True):
""" """
Assign Local Roles to Groups on object 'ob', based on Portal Type Role Assign Local Roles to Groups on object 'ob', based on Portal Type Role
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment