Project

General

Profile

Actions

Patch #7594

closed

Proper pagination

Patch #7594: Proper pagination

Added by Brian Lindahl almost 16 years ago. Updated over 11 years ago.

Status:
Closed
Priority:
High
Assignee:
-
Category:
UI
Target version:
-

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 4 (0 open — 4 closed)

Related to Redmine - Defect #1965: Redmine is not Tab SafeClosedJean-Philippe LangActions
Related to Redmine - Defect #657: Back button - loses current page after viewing an issue - IE onlyClosedJean-Philippe LangActions
Related to Redmine - Defect #3494: Browser "Back" to issue list displays wrong filterClosedActions
Is duplicate of Redmine - Defect #5138: Don't use Ajax for paginationClosedActions

Updated by Brian Lindahl almost 16 years ago Actions #1

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.

Updated by Brian Lindahl almost 16 years ago Actions #2

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

Updated by Brian Lindahl almost 16 years ago Actions #3

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

Updated by Toshi MARUYAMA over 15 years ago Actions #4

  • Category set to UI

Updated by Go MAEDA over 11 years ago Actions #5

  • Status changed from New to Closed

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

Updated by Go MAEDA over 11 years ago Actions #6

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

Also available in: PDF Atom