index
Invalid request
ble'>0.8-stable Mirror of redmine code source: https://github.com/redmine/redminewww-data
summaryrefslogtreecommitdiffstats
path: root/app/views/users/index.html.erb
blob: f88b5231e2f8bb73b4a144fa831326a183f614e0 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
<div class="contextual">
<%= link_to l(:label_user_new), new_user_path, :class => 'icon icon-add' %>
</div>

<h2><%=l(:label_user_plural)%></h2>

<%= form_tag({}, :method => :get) do %>
<fieldset><legend><%= l(:label_filter_plural) %></legend>
<label for='status'><%= l(:field_status) %>:</label>
<%= select_tag 'status', users_status_options_for_select(@status), :class => "small", :onchange => "this.form.submit(); return false;"  %>

<% if @groups.present? %>
<label for='group_id'><%= l(:label_group) %>:</label>
<%= 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>
<%= text_field_tag 'name', params[:name], :size => 30 %>
<%= submit_tag l(:button_apply), :class => "small", :name => nil %>
<%= link_to l(:button_clear), users_path, :class => 'icon icon-reload' %>
</fieldset>
<% end %>
&nbsp;

<div class="autoscroll">
<table class="list">
  <thead><tr>
  <%= sort_header_tag('login', :caption => l(:field_login)) %>
  <%= sort_header_tag('firstname', :caption => l(:field_firstname)) %>
  <%= sort_header_tag('lastname', :caption => l(:field_lastname)) %>
  <%= sort_header_tag('mail', :caption => l(:field_mail)) %>
  <%= sort_header_tag('admin', :caption => l(:field_admin), :default_order => 'desc') %>
  <%= sort_header_tag('created_on', :caption => l(:field_created_on), :default_order => 'desc') %>
  <%= sort_header_tag('last_login_on', :caption => l(:field_last_login_on), :default_order => 'desc') %>
    <th></th>
  </tr></thead>
  <tbody>
<% for user in @users -%>
  <tr class="user <%= cycle("odd", "even") %> <%= %w(anon active registered locked)[user.status] %>">
  <td class="username"><%= avatar(user, :size => "14") %><%= link_to h(user.login), edit_user_path(user) %></td>
  <td class="firstname"><%= h(user.firstname) %></td>
  <td class="lastname"><%= h(user.lastname) %></td>
  <td class="email"><%= mail_to(h(user.mail)) %></td>
  <td align="center"><%= checked_image user.admin? %></td>
  <td class="created_on" align="center"><%= format_time(user.created_on) %></td>
  <td class="last_login_on" align="center"><%= format_time(user.last_login_on) unless user.last_login_on.nil? %></td>
    <td class="buttons">
      <%= change_status_link(user) %>
      <%= delete_link user_path(user, :back_url => users_path(params)) unless User.current == user %>
    </td>
  </tr>
<% end -%>
  </tbody>
</table>
</div>
<p class="pagination"><%= pagination_links_full @user_pages, @user_count %></p>

<% html_title(l(:label_user_plural)) -%>