admin-panel-fix
Some checks failed
Deploy on push / deploy (push) Has been cancelled

This commit is contained in:
2025-08-31 23:51:12 +03:00
parent 537f1db2db
commit 3086f22c2e

View File

@@ -72,7 +72,10 @@ async def admin_get_shouts(
) -> dict[str, Any]:
"""Получает список публикаций"""
try:
return await admin_service.get_shouts(limit, offset, search, status, community)
# Конвертируем limit/offset в page/per_page
page = (offset // limit) + 1 if limit > 0 else 1
per_page = limit
return await admin_service.get_shouts(page, per_page, search, status, community)
except Exception as e:
raise handle_error("получении списка публикаций", e) from e