def METHOD_NAME(self):
    queryset = (
        LogEntry.objects.all()
        .prefetch_related("actor")
        .prefetch_related("user")
        .prefetch_related("share_owner")
        .prefetch_related("share_owner__user")
        .prefetch_related("log_class_type")
    )
    if not self.request.user.has_perm(PERMISSION_COOP_VIEW):
        return queryset.filter(user=self.request.user)
    return queryset