From: Jean-Philippe Lang Date: Wed, 11 Nov 2009 11:35:27 +0000 (+0000) Subject: Redirect to the current page when using context menu on the issue list (#4184). X-Git-Tag: 0.9.0~223 X-Git-Url: https://source.dussan.org/?a=commitdiff_plain;h=58103680bdfe3cf404267504bf8dd2155140fa61;p=redmine.git Redirect to the current page when using context menu on the issue list (#4184). git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@3027 e93f8b46-1217-0410-a6f0-8f06a7374b81 --- diff --git a/app/controllers/issues_controller.rb b/app/controllers/issues_controller.rb index f484ed82e..a4f3de3d1 100644 --- a/app/controllers/issues_controller.rb +++ b/app/controllers/issues_controller.rb @@ -424,7 +424,7 @@ class IssuesController < ApplicationController @priorities = IssuePriority.all.reverse @statuses = IssueStatus.find(:all, :order => 'position') - @back = request.env['HTTP_REFERER'] + @back = params[:back_url] || request.env['HTTP_REFERER'] render :layout => false end diff --git a/app/views/issues/_list.rhtml b/app/views/issues/_list.rhtml index 43a41cd77..9d4ef7dd8 100644 --- a/app/views/issues/_list.rhtml +++ b/app/views/issues/_list.rhtml @@ -1,4 +1,5 @@ <% form_tag({}) do -%> +<%= hidden_field_tag 'back_url', url_for(params) %>
<%= link_to image_tag('toggle_check.png'), {}, :onclick => 'toggleIssuesSelection(Element.up(this, "form")); return false;',