from .models import Role class RoleService: @staticmethod def get_roles(): roles = Role.query.all() return [{"id": r.id, "name": r.name} for r in roles]