auth and rbac improves
Some checks failed
Deploy on push / deploy (push) Failing after 31s

This commit is contained in:
2025-08-20 18:33:58 +03:00
parent fe76eef273
commit ba3f006f1f
10 changed files with 410 additions and 178 deletions

View File

@@ -40,6 +40,18 @@ class RBACOperations(Protocol):
"""Проверяет, есть ли у набора ролей конкретное разрешение в сообществе"""
...
def assign_role_to_user(self, author_id: int, role: str, community_id: int, session: Any = None) -> bool:
"""Назначает роль пользователю в сообществе"""
...
def get_user_roles_in_community(self, author_id: int, community_id: int, session: Any = None) -> list[str]:
"""Получает роли пользователя в сообществе"""
...
def remove_role_from_user(self, author_id: int, role: str, community_id: int, session: Any = None) -> bool:
"""Удаляет роль у пользователя в сообществе"""
...
class CommunityAuthorQueries(Protocol):
"""