Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse code

Merge pull request #1265 from dbrgn/mixin_order

Fixed order of base classes in CBV mixin docs
  • Loading branch information...
commit 675558d00efab507ef2e538025f20abc6725b159 2 parents 3ce1d30 + cd7d745
Marc Tamlyn authored June 13, 2013

Showing 1 changed file with 3 additions and 3 deletions. Show diff stats Hide diff stats

  1. 6  docs/topics/class-based-views/mixins.txt
6  docs/topics/class-based-views/mixins.txt
@@ -233,7 +233,7 @@ We'll demonstrate this with the publisher modelling we used in the
233 233
     from django.views.generic.detail import SingleObjectMixin
234 234
     from books.models import Author
235 235
 
236  
-    class RecordInterest(View, SingleObjectMixin):
  236
+    class RecordInterest(SingleObjectMixin, View):
237 237
         """Records the current user's interest in an author."""
238 238
         model = Author
239 239
 
@@ -446,7 +446,7 @@ Our new ``AuthorDetail`` looks like this::
446 446
     class AuthorInterestForm(forms.Form):
447 447
         message = forms.CharField()
448 448
 
449  
-    class AuthorDetail(DetailView, FormMixin):
  449
+    class AuthorDetail(FormMixin, DetailView):
450 450
         model = Author
451 451
         form_class = AuthorInterestForm
452 452
 
@@ -553,7 +553,7 @@ template as ``AuthorDisplay`` is using on ``GET``.
553 553
     from django.views.generic import FormView
554 554
     from django.views.generic.detail import SingleObjectMixin
555 555
 
556  
-    class AuthorInterest(FormView, SingleObjectMixin):
  556
+    class AuthorInterest(SingleObjectMixin, FormView):
557 557
         template_name = 'books/author_detail.html'
558 558
         form_class = AuthorInterestForm
559 559
         model = Author

0 notes on commit 675558d

Please sign in to comment.
Something went wrong with that request. Please try again.