Project

General

Profile

Actions

Patch #7594

closed

Proper pagination

Added by Brian Lindahl about 13 years ago. Updated almost 9 years ago.

Status:
Closed
Priority:
High
Assignee:
-
Category:
UI
Target version:
-
Start date:
2011-02-09
Due date:
% Done:

50%

Estimated time:

Description

There are some serious problems with the way pagination (i.e. issue list) is implemented.
1) back button is broken
2) bookmarking is broken

This patch isn't a perfect fix, but it's a good hack/patch to use while waiting for a more proper solution to this problem. The root cause is based in using Ajax updates for pagination. Since the page isn't changing, the browser history isn't managed, nor is the URL updated. By moving back to direct links for pagination, this problem can be avoided. Note that in this patch, a lot of Ajax parameters are removed so that they don't show up in the URL. This may introduce problems with maintaining said Ajax properties across pagination.

I've introduced a Ruby hash to isolate these problematic parameters and controllers. By updating turning on logging (uncommenting a line in the patch), you can identify the name of the controller and the name of the parameter that needs to be preserved. The name of the parameter can then be added to the hash, keyed by the name of the controller. This parameter will now appear in the URL and the Ajax parameter will be preserved across pagination. Note that I have only noticed this problem in the users controller, when changing the status or the name query.

It appears that issue grouping and issue filtering (the most important Ajax parameters, in my opinion), are preserved across pagination. However, these Ajax parameters are not preserved across bookmarks. Fortunately, saved queries makes this a non-issue.


Files

proper-pagination-1.1.0.patch (3.15 KB) proper-pagination-1.1.0.patch Brian Lindahl, 2011-02-09 21:04
proper-pagination-1.1.0.patch (3.15 KB) proper-pagination-1.1.0.patch bugfix1 Brian Lindahl, 2011-02-09 22:00

Related issues

Related to Redmine - Defect #1965: Redmine is not Tab SafeClosedJean-Philippe Lang2008-09-29

Actions
Related to Redmine - Defect #657: Back button - loses current page after viewing an issue - IE onlyClosedJean-Philippe Lang2008-02-13

Actions
Related to Redmine - Defect #3494: Browser "Back" to issue list displays wrong filterClosed2009-06-13

Actions
Is duplicate of Redmine - Defect #5138: Don't use Ajax for paginationClosed2010-03-20

Actions
Actions #1

Updated by Brian Lindahl about 13 years ago

There are likely issues with this patch that have not been uncovered yet. However, they will not be catastrophic (i.e. trash the database, take down the site, or cause errors in pages). The issues with this patch will most likely be related to Ajax configurations (parameters) of views disappearing when using pagination.

Actions #2

Updated by Brian Lindahl about 13 years ago

bugfix1:
  • project_id wasn't being preserved, so the project was lost during pagination
Actions #3

Updated by Brian Lindahl about 13 years ago

related to #1965, #657, #5138, #3494

Actions #4

Updated by Toshi MARUYAMA almost 13 years ago

  • Category set to UI
Actions #5

Updated by Go MAEDA almost 9 years ago

  • Status changed from New to Closed

Fixed by #5138 (Redmine 1.2.0), removed ajax pagination.

Actions #6

Updated by Go MAEDA almost 9 years ago

  • Is duplicate of Defect #5138: Don't use Ajax for pagination added
Actions

Also available in: Atom PDF