From d4c6abcbd10da9816a834883f3bfb05fb67222bc Mon Sep 17 00:00:00 2001 From: Luke Plant Date: Sat, 20 Nov 2010 20:38:52 +0000 Subject: Documented migration path for change object_list -> ListView regarding different context variables git-svn-id: http://code.djangoproject.com/svn/django/trunk@14650 bcc190cf-cafb-0310-a4f2-bffc1f526a37 --- docs/topics/generic-views-migration.txt | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) (limited to 'docs') diff --git a/docs/topics/generic-views-migration.txt b/docs/topics/generic-views-migration.txt index 3ac4204413..407ef24e49 100644 --- a/docs/topics/generic-views-migration.txt +++ b/docs/topics/generic-views-migration.txt @@ -74,6 +74,26 @@ was appended with the suffix ``'_list'`` to yield the final context variable name. In a class-based ``ListView``, the ``context_object_name`` is used verbatim. +The context data for ``object_list`` views +------------------------------------------ + +The context provided by :class:`~django.views.generic.list.MultipleObjectMixin` +is quite different from that provided by ``object_list``, with most pagination +related variables replaced by a single ``page_obj`` object. The following are no +longer provided: + +* ``first_on_page`` +* ``has_next`` +* ``has_previous`` +* ``hits`` +* ``last_on_page`` +* ``next`` +* ``page_range`` +* ``page`` +* ``pages`` +* ``previous`` +* ``results_per_page`` + ``extra_context`` ----------------- -- cgit v1.3