index 04cfd76ab6cb3689d59d7ebc108c8d0904f1c3d9..b0eaf022bc34120b2084c9bc433d5d39b7dd5e1a 100644 (file)
</script>
"""%self.base
- def batch(self):
+ def batch(self, permission='View'):
""" Return a batch object for results from the "current search"
"""
check = self._client.db.security.hasPermission
# filter for visibility
l = [id for id in klass.filter(matches, filterspec, sort, group)
- if check('View', userid, self.classname, itemid=id)]
+ if check(permission, userid, self.classname, itemid=id)]
# return the batch object, using IDs only
return Batch(self.client, l, self.pagesize, self.startwith,