<%= form_tag({}) do -%>
-<%= hidden_field_tag 'back_url', url_for(params), :id => nil %>
+<%= hidden_field_tag 'back_url', url_for(:params => request.query_parameters), :id => nil %>
<div class="autoscroll">
<table class="list issues <%= sort_css_classes %>">
<thead>
<%= form_tag({}) do -%>
-<%= hidden_field_tag 'back_url', url_for(params) %>
+<%= hidden_field_tag 'back_url', url_for(:params => request.query_parameters), :id => nil %>
<div class="autoscroll">
<table class="list time-entries">
<thead>
end
end
+ def test_index_should_include_back_url_input
+ get :index, :project_id => 'ecookbook', :foo => 'bar'
+ assert_response :success
+ assert_select 'input[name=back_url][value=?]', '/projects/ecookbook/issues?foo=bar'
+ end
+
def test_index_sort
get :index, :sort => 'tracker,id:desc'
assert_response :success