Commit 22754773 authored by Sebastien Robin's avatar Sebastien Robin Committed by iv

ERP5PersistentMappingFolder: objectValues must return objects with acquisition wrappers.

Also remove assertion on "spec is None", otherwise we have failure (it is used
by portal_caches somewhere).
parent 2b13e39f
...@@ -96,7 +96,7 @@ class ERP5PersistentMappingFolder(PortalFolderBase): ...@@ -96,7 +96,7 @@ class ERP5PersistentMappingFolder(PortalFolderBase):
sort_order=None, checked_permission=None, **kw): sort_order=None, checked_permission=None, **kw):
# Returns list of objects contained in this folder. # Returns list of objects contained in this folder.
# (no docstring to prevent publishing) # (no docstring to prevent publishing)
assert(spec is None) #assert(spec is None)
if self._object_dict is None: if self._object_dict is None:
return [] return []
...@@ -111,7 +111,7 @@ class ERP5PersistentMappingFolder(PortalFolderBase): ...@@ -111,7 +111,7 @@ class ERP5PersistentMappingFolder(PortalFolderBase):
checkPermission = getSecurityManager().checkPermission checkPermission = getSecurityManager().checkPermission
object_list = [o for o in object_list object_list = [o for o in object_list
if checkPermission(checked_permission, o)] if checkPermission(checked_permission, o)]
return sortValueList(object_list, sort_on, sort_order, **kw) return [x.__of__(self) for x in sortValueList(object_list, sort_on, sort_order, **kw)]
security.declareProtected(Permissions.AccessContentsInformation, security.declareProtected(Permissions.AccessContentsInformation,
'keys', 'items', 'values') 'keys', 'items', 'values')
......
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