##// END OF EJS Templates
Adds name filter on group list....
Jean-Philippe Lang -
r15375:52fbcebb6dfd
parent child
Show More
@@ -3,6 +3,17
3 </div>
3 </div>
4
4
5 <%= title l(:label_group_plural) %>
5 <%= title l(:label_group_plural) %>
6
7 <%= form_tag(groups_path, :method => :get) do %>
8 <fieldset><legend><%= l(:label_filter_plural) %></legend>
9 <label for='name'><%= l(:label_group) %>:</label>
10 <%= text_field_tag 'name', params[:name], :size => 30 %>
11 <%= submit_tag l(:button_apply), :class => "small", :name => nil %>
12 <%= link_to l(:button_clear), groups_path, :class => 'icon icon-reload' %>
13 </fieldset>
14 <% end %>
15 &nbsp;
16
6 <% if @groups.any? %>
17 <% if @groups.any? %>
7 <div class="autoscroll">
18 <div class="autoscroll">
8 <table class="list groups">
19 <table class="list groups">
@@ -36,6 +36,15 class GroupsControllerTest < Redmine::ControllerTest
36 assert_select 'tr#group-11 td.user_count', :text => '1'
36 assert_select 'tr#group-11 td.user_count', :text => '1'
37 end
37 end
38
38
39 def test_index_with_name_filter
40 Group.generate!(:name => "Clients")
41
42 get :index, :name => "cli"
43 assert_response :success
44 assert_select 'table.groups tbody tr', 1
45 assert_select 'table.groups tbody td.name', :text => 'Clients'
46 end
47
39 def test_show
48 def test_show
40 get :show, :id => 10
49 get :show, :id => 10
41 assert_response :success
50 assert_response :success
General Comments 0
You need to be logged in to leave comments. Login now