sharing/collection-list: rename function
This commit is contained in:
@@ -322,16 +322,17 @@ class BaseSharing:
|
|||||||
return True
|
return True
|
||||||
|
|
||||||
# *** sharing functions called by request methods ***
|
# *** sharing functions called by request methods ***
|
||||||
# list sharings of type "map"
|
# list sharings
|
||||||
def sharing_collection_map_list(self, User: Union[str, None] = None, Enabled: Union[bool, None] = None, Hidden: Union[bool, None] = None) -> list[dict]:
|
def sharing_collection_list(self, User: Union[str, None] = None, Enabled: Union[bool, None] = None, Hidden: Union[bool, None] = None) -> list[dict]:
|
||||||
""" returning dict with shared collections by filter(User/Enabled/Hidden) or None if not found"""
|
""" returning dict with shared collections by filter(User/Enabled/Hidden) or None if not found"""
|
||||||
|
sharing_collection_list = []
|
||||||
|
|
||||||
if not self.sharing_collection_by_map:
|
if not self.sharing_collection_by_map:
|
||||||
if logger.isEnabledFor(logging.DEBUG):
|
if logger.isEnabledFor(logging.DEBUG):
|
||||||
logger.debug("TRACE/sharing/map: not active")
|
logger.debug("TRACE/sharing/map: not active")
|
||||||
return []
|
else:
|
||||||
|
# retrieve collections depending on filter
|
||||||
# retrieve collections depending on filter
|
sharing_collection_list += self.database_list_sharing(
|
||||||
shared_collection_list = self.database_list_sharing(
|
|
||||||
ShareType="map",
|
ShareType="map",
|
||||||
OwnerOrUser=User,
|
OwnerOrUser=User,
|
||||||
User=User,
|
User=User,
|
||||||
@@ -340,8 +341,7 @@ class BaseSharing:
|
|||||||
HiddenByOwner=Hidden,
|
HiddenByOwner=Hidden,
|
||||||
HiddenByUser=Hidden)
|
HiddenByUser=Hidden)
|
||||||
|
|
||||||
# final
|
return sharing_collection_list
|
||||||
return shared_collection_list
|
|
||||||
|
|
||||||
# resolves a path to a share
|
# resolves a path to a share
|
||||||
def sharing_collection_resolver(self, path: str, user: str) -> Union[dict, None]:
|
def sharing_collection_resolver(self, path: str, user: str) -> Union[dict, None]:
|
||||||
|
|||||||
Reference in New Issue
Block a user