Opened 19 years ago

Closed 19 years ago

#947 closed defect (fixed)

[patch] is_paginated is true when number of pages is 1

Reported by: Nebojša Đorđević - nesh <nesh@…> Owned by: Jacob
Component: Generic views Version:
Severity: normal Keywords:
Cc: nesh@… Triage Stage: Unreviewed
Has patch: yes Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: no UI/UX: no

Description

Index: /store/django/django/views/generic/list_detail.py
===================================================================
--- /store/django/django/views/generic/list_detail.py   (revision 1474)
+++ /store/django/django/views/generic/list_detail.py   (working copy)
@@ -50,7 +50,7 @@
         page = int(page)
         c = Context(request, {
             'object_list': object_list,
-            'is_paginated': True,
+            'is_paginated': paginator.pages > 1,
             'results_per_page': paginate_by,
             'has_next': paginator.has_next_page(page),
             'has_previous': paginator.has_previous_page(page),

Change History (2)

comment:1 by Nebojša Đorđević - nesh <nesh@…>, 19 years ago

Cc: nesh@… added

comment:2 by Adrian Holovaty, 19 years ago

Resolution: fixed
Status: newclosed

(In [1478]) Fixed #947 -- Corrected is_paginated variable in list_detail generic view. Thanks, nesh

Note: See TracTickets for help on using tickets.
Back to Top