limit-offset-patch

This commit is contained in:
2022-09-14 12:45:31 +03:00
parent 90439d931d
commit 66cd20514e
6 changed files with 79 additions and 91 deletions

View File

@@ -113,7 +113,7 @@ async def delete_reaction(_, info, id):
@query.field("reactionsByShout")
async def get_shout_reactions(_, info, slug, page, size):
async def get_shout_reactions(_, info, slug, offset, limit):
offset = page * size
reactions = []
with local_session() as session:
@@ -130,7 +130,7 @@ async def get_shout_reactions(_, info, slug, page, size):
@query.field("reactionsForShouts")
async def get_reactions_for_shouts(_, info, shouts, page, size):
async def get_reactions_for_shouts(_, info, shouts, offset, limit):
offset = page * size
reactions = []
with local_session() as session: