from rest_framework import permissions, viewsets

from discgolf.api import serializers
from discgolf import models


class DiscGolfCourseViewSet(viewsets.ModelViewSet):
    queryset = models.DiscGolfCourse.objects.all().order_by("-created")
    serializer_class = serializers.DiscGolfCourseSerializer
    permission_classes = [permissions.IsAuthenticated]



