Feature: Add tests and migrations for board in backend

This commit is contained in:
winkidney
2020-02-11 17:11:39 +08:00
parent 23aacbc7c0
commit c31d93f797
3 changed files with 68 additions and 2 deletions

View File

@@ -56,6 +56,7 @@ class BoardAutoCompleteViewSet(
ordering_fields = ('-id', )
ordering = ('-id', )
pagination_class = None
permission_classes = [OwnerOnlyIfPrivate("submitter"), ]
def get_queryset(self):
return filter_private_board(self.request, Board.objects.all())