Browse Source

Fixed that group filter is escaped on users index.

git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@9679 e93f8b46-1217-0410-a6f0-8f06a7374b81
tags/2.0.0
Jean-Philippe Lang 12 years ago
parent
commit
dc7569ecae
2 changed files with 4 additions and 1 deletions
  1. 1
    1
      app/views/users/index.html.erb
  2. 3
    0
      test/functional/users_controller_test.rb

+ 1
- 1
app/views/users/index.html.erb View File

@@ -11,7 +11,7 @@

<% if @groups.present? %>
<label for='group_id'><%= l(:label_group) %>:</label>
<%= select_tag 'group_id', '<option></option>' + options_from_collection_for_select(@groups, :id, :name, params[:group_id].to_i), :onchange => "this.form.submit(); return false;" %>
<%= select_tag 'group_id', content_tag('option') + options_from_collection_for_select(@groups, :id, :name, params[:group_id].to_i), :onchange => "this.form.submit(); return false;" %>
<% end %>

<label for='name'><%= l(:label_user) %>:</label>

+ 3
- 0
test/functional/users_controller_test.rb View File

@@ -74,6 +74,9 @@ class UsersControllerTest < ActionController::TestCase
users = assigns(:users)
assert users.any?
assert_equal([], (users - Group.find(10).users))
assert_select 'select[name=group_id]' do
assert_select 'option[value=10][selected=selected]'
end
end

def test_show

Loading…
Cancel
Save