feat : init elements

This commit is contained in:
swve 2022-11-06 16:11:46 +01:00
parent b1ed0185f9
commit 6a2bea4293
8 changed files with 269 additions and 60 deletions

View file

@ -23,6 +23,9 @@ class CollectionInDB(Collection):
#### Classes ####################################################
####################################################
# CRUD
####################################################
async def get_collection(collection_id: str, current_user: PublicUser):
await check_database()
@ -112,6 +115,9 @@ async def delete_collection(collection_id: str, current_user: PublicUser):
raise HTTPException(
status_code=status.HTTP_503_SERVICE_UNAVAILABLE, detail="Unavailable database")
####################################################
# Misc
####################################################
async def get_collections(page: int = 1, limit: int = 10):
## TODO : auth