summaryrefslogtreecommitdiffstats
path: root/app/controllers/issues_controller.rb
diff options
context:
space:
mode:
authorJean-Philippe Lang <jp_lang@yahoo.fr>2017-04-04 17:49:40 +0000
committerJean-Philippe Lang <jp_lang@yahoo.fr>2017-04-04 17:49:40 +0000
commit8fe94c30fe2a5044eda08d9bb73a2e5391273511 (patch)
tree2ee66a974fde980aaca100137fe8910fed79c284 /app/controllers/issues_controller.rb
parent7b125bc2924125200e13bdbe5dc4c04e3078d157 (diff)
downloadredmine-8fe94c30fe2a5044eda08d9bb73a2e5391273511.tar.gz
redmine-8fe94c30fe2a5044eda08d9bb73a2e5391273511.zip
Adds a link back to the issue list that we are coming from.
git-svn-id: http://svn.redmine.org/redmine/trunk@16478 e93f8b46-1217-0410-a6f0-8f06a7374b81
Diffstat (limited to 'app/controllers/issues_controller.rb')
-rw-r--r--app/controllers/issues_controller.rb6
1 files changed, 6 insertions, 0 deletions
diff --git a/app/controllers/issues_controller.rb b/app/controllers/issues_controller.rb
index 73f2eb404..b6c72a314 100644
--- a/app/controllers/issues_controller.rb
+++ b/app/controllers/issues_controller.rb
@@ -412,6 +412,7 @@ class IssuesController < ApplicationController
else
retrieve_query_from_session
if @query
+ @per_page = per_page_option
limit = 500
issue_ids = @query.issue_ids(:limit => (limit + 1))
if (idx = issue_ids.index(@issue.id)) && idx < limit
@@ -422,6 +423,11 @@ class IssuesController < ApplicationController
@prev_issue_id = issue_ids[idx - 1] if idx > 0
@next_issue_id = issue_ids[idx + 1] if idx < (issue_ids.size - 1)
end
+ query_params = @query.as_params
+ if @issue_position
+ query_params = query_params.merge(:page => (@issue_position / per_page_option) + 1, :per_page => per_page_option)
+ end
+ @query_path = _project_issues_path(@query.project, query_params)
end
end
end