Opened 12 years ago

Closed 12 years ago

Last modified 11 years ago

#1033 closed enhancement (fixed)

[patch] Generic view `list_detail` pagination should be one-indexed in URL

Reported by: Tom Tobin <korpios@…> Owned by: Jacob
Component: Generic views Version:
Severity: normal Keywords:
Cc: Triage Stage: Unreviewed
Has patch: yes Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: UI/UX:


While having the ObjectPaginator class be zero-indexed internally makes sense, having the GET variable for the current page number also be zero-indexed doesn't; one-indexed numbers are all a user should have to understand, and it's doubly confusing to be visiting a page claiming to be "3 of 4" yet have ?page=2 in the URL.

The attached patch fixes the list_detail generic view to be one-indexed, while leaving ObjectPaginator alone (i.e., zero-indexed).

Attachments (1)

list_detail_oneindexed.diff (1.4 KB) - added by Tom Tobin <korpios@…> 12 years ago.
Implements one-indexed list_detail generic view

Download all attachments as: .zip

Change History (3)

Changed 12 years ago by Tom Tobin <korpios@…>

Attachment: list_detail_oneindexed.diff added

Implements one-indexed list_detail generic view

comment:1 Changed 12 years ago by Jacob

Resolution: fixed
Status: newclosed

(In [2426]) Fixed #1033 -- pagination in object_list generic views now use 1-indexed page numbers in the URL. Thanks, Tom Tobin.

comment:2 Changed 11 years ago by korpios

Reporter: changed from Tom Tobin <korpios@…> to Tom Tobin <korpios@…>
Note: See TracTickets for help on using tickets.
Back to Top