def check_thread_permissions(self, request, thread):
        add_acl(request.user, thread.forum)
        add_acl(request.user, thread)

        self.fetch_thread_participants(request.user, thread)

        allow_see_private_thread(request.user, thread)
        allow_use_private_threads(request.user)
示例#2
0
    def check_post_permissions(self, request, post):
        add_acl(request.user, post.forum)
        add_acl(request.user, post.thread)
        add_acl(request.user, post)

        participants.make_thread_participants_aware(request.user, thread)

        allow_see_private_post(request.user, post)
        allow_see_private_thread(request.user, post.thread)
        allow_use_private_threads(request.user)
 def check_forum_permissions(self, request, forum):
     add_acl(request.user, forum)
     allow_use_private_threads(request.user)
 def dispatch(self, request, *args, **kwargs):
     allow_use_private_threads(request.user)
     return f(self, request, *args, **kwargs)
    def get_category(self, request, categories, **kwargs):
        allow_use_private_threads(request.user)

        return categories[0]