示例#1
0
 def share(self, system, file_path, username, permission):
     f = BaseFileResource(self._ag, system, file_path)
     recursive = True
     pem = BaseFilePermissionResource(self._ag, f, recursive=recursive)
     pem.username = username
     pem.permission_bit = permission
     resp = pem.save()
     reindex_agave.apply_async(kwargs = {'username': '******',
                                         'file_id': '{}/{}'.format(system, file_path)})
     return resp
示例#2
0
 def list_permissions(self, system, file_path):
     f = BaseFileResource(self._ag, system, file_path)
     return BaseFilePermissionResource.list_permissions(self._ag, f)