index.html.erb
58 lines
| 2.6 KiB
| text/plain
|
TextLexer
|
r90 | <div class="contextual"> | ||
|
r4115 | <%= link_to l(:label_user_new), {:action => 'new'}, :class => 'icon icon-add' %> | ||
|
r90 | </div> | ||
|
r12 | <h2><%=l(:label_user_plural)%></h2> | ||
|
r330 | |||
|
r1104 | <% form_tag({}, :method => :get) do %> | ||
|
r344 | <fieldset><legend><%= l(:label_filter_plural) %></legend> | ||
|
r1943 | <label><%= l(:field_status) %>:</label> | ||
|
r1734 | <%= select_tag 'status', users_status_options_for_select(@status), :class => "small", :onchange => "this.form.submit(); return false;" %> | ||
|
r5030 | |||
<% if @groups.present? %> | ||||
<label><%= 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;" %> | ||||
<% end %> | ||||
|
r1943 | <label><%= l(:label_user) %>:</label> | ||
<%= text_field_tag 'name', params[:name], :size => 30 %> | ||||
<%= submit_tag l(:button_apply), :class => "small", :name => nil %> | ||||
|
r5031 | <%= link_to l(:button_clear), users_path, :class => 'icon icon-reload' %> | ||
|
r344 | </fieldset> | ||
<% end %> | ||||
| ||||
|
r3262 | <div class="autoscroll"> | ||
|
r7245 | <table class="list"> | ||
|
r105 | <thead><tr> | ||
|
r7245 | <%= 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') %> | ||||
|
r330 | <th></th> | ||
|
r105 | </tr></thead> | ||
<tbody> | ||||
|
r1104 | <% for user in @users -%> | ||
<tr class="user <%= cycle("odd", "even") %> <%= %w(anon active registered locked)[user.status] %>"> | ||||
|
r7245 | <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> | ||||
|
r4609 | <td class="buttons"> | ||
|
r7245 | <%= change_status_link(user) %> | ||
<%= link_to(l(:button_delete), user, :confirm => l(:text_are_you_sure), :method => :delete, :class => 'icon icon-del') unless User.current == user %> | ||||
|
r4609 | </td> | ||
|
r2 | </tr> | ||
|
r1104 | <% end -%> | ||
|
r105 | </tbody> | ||
|
r2 | </table> | ||
|
r3262 | </div> | ||
|
r1013 | <p class="pagination"><%= pagination_links_full @user_pages, @user_count %></p> | ||
|
r951 | |||
|
r1019 | <% html_title(l(:label_user_plural)) -%> | ||