diff options
| author | Tom Christie | 2012-09-20 13:06:27 +0100 | 
|---|---|---|
| committer | Tom Christie | 2012-09-20 13:06:27 +0100 | 
| commit | 4b691c402707775c3048a90531024f3bc5be6f91 (patch) | |
| tree | 3adfc54b0d8b70e4ea78edf7091f7827fa68f47b /docs/tutorial/3-class-based-views.md | |
| parent | a1bcfbfe926621820832e32b0427601e1140b4f7 (diff) | |
| download | django-rest-framework-4b691c402707775c3048a90531024f3bc5be6f91.tar.bz2 | |
Change package name: djangorestframework -> rest_framework
Diffstat (limited to 'docs/tutorial/3-class-based-views.md')
| -rw-r--r-- | docs/tutorial/3-class-based-views.md | 14 | 
1 files changed, 7 insertions, 7 deletions
| diff --git a/docs/tutorial/3-class-based-views.md b/docs/tutorial/3-class-based-views.md index 79866f0d..8db29308 100644 --- a/docs/tutorial/3-class-based-views.md +++ b/docs/tutorial/3-class-based-views.md @@ -9,9 +9,9 @@ We'll start by rewriting the root view as a class based view.  All this involves      from blog.models import Comment      from blog.serializers import CommentSerializer      from django.http import Http404 -    from djangorestframework.views import APIView -    from djangorestframework.response import Response -    from djangorestframework import status +    from rest_framework.views import APIView +    from rest_framework.response import Response +    from rest_framework import status      class CommentRoot(APIView): @@ -68,7 +68,7 @@ That's looking good.  Again, it's still pretty similar to the function based vie  We'll also need to refactor our URLconf slightly now we're using class based views.      from django.conf.urls import patterns, url -    from djangorestframework.urlpatterns import format_suffix_patterns +    from rest_framework.urlpatterns import format_suffix_patterns      from blogpost import views      urlpatterns = patterns('', @@ -90,8 +90,8 @@ Let's take a look at how we can compose our views by using the mixin classes.      from blog.models import Comment      from blog.serializers import CommentSerializer -    from djangorestframework import mixins -    from djangorestframework import generics +    from rest_framework import mixins +    from rest_framework import generics      class CommentRoot(mixins.ListModelMixin,                        mixins.CreateModelMixin, @@ -133,7 +133,7 @@ Using the mixin classes we've rewritten the views to use slightly less code than      from blog.models import Comment      from blog.serializers import CommentSerializer -    from djangorestframework import generics +    from rest_framework import generics      class CommentRoot(generics.RootAPIView): | 
