Commit 862e01aa authored by Daniel W Bond's avatar Daniel W Bond
Browse files

added comments for api app

parent 4327b240
......@@ -107,6 +107,8 @@ class MajorSerializer(serializers.ModelSerializer):
fields = ('name', )
# the first major serializer is used when listing majors; this is used for the
# object's own page's display
class MajorURLSerializer(serializers.ModelSerializer):
class Meta:
......
......@@ -90,7 +90,8 @@ class MajorRetrieve(RetrieveAPIView):
lookup_field = 'slug'
# root urls
# root urls-- custom version of drf's root DefaultRouter, because we're doing
# atypical things with url handling and aren't using out-of-the-box routers
class APIRoot(APIView):
def get(self, request):
return Response({
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment