Sha256: e369e6c9a3e34eacd50b69f2570cb8f1850e6b18afb055505430e837ec881ed4

Contents?: true

Size: 1.26 KB

Versions: 5

Compression:

Stored size: 1.26 KB

Contents

<h1><%= t('activerecord.models.users') %></h1>

<%= render 'details/tab_admin_menu' %>

<table class='table table-striped'>
	<thead>
  <tr>
			<th><%= t 'authentication.name' %></th>
	    <th><%= t 'activerecord.attributes.user.email' %></th>
			<th><%= t('question_mark_inverted') %><%= t('activerecord.attributes.user.admin') %><%= t('question_mark') %></th>
			<th><%= t('actions') %></th>
	  </tr>
	</thead>

	<tbody>
		<% @users.each do |user| %>
		  <tr>
		    <td><%= link_to user.name, member_path(user) %></td>
				<td><%= user.email %></td>
				<td>
					<% unless user.admin? %>
					  <span class="label label-danger">X</span> <%= link_to t('authentication.enable_admin'), make_admin_user_path(user), class: 'btn btn-xs btn-default', method: :post %>
					<% else %>
						<span class="label label-success">✓</span> <%= link_to t('authentication.disable_admin'), remove_admin_user_path(user), class: 'btn btn-xs btn-primary', method: :post %>
					<% end -%>
				</td>
				<td><%= link_to t('edit'), edit_member_path(user), class: 'btn btn-xs btn-default' %><%= link_to t('delete'), Member.find(user.id), method: :delete, data: { confirm: t('are_you_sure') }, class: 'btn btn-xs btn-danger' %></td>
		  </tr>
		<% end %>
	</tbody>
</table>

<%= render 'shared/admin_sidebar' %>

Version data entries

5 entries across 5 versions & 1 rubygems

Version Path
tkh_authentication-0.9.17.2 app/views/users/index.html.erb
tkh_authentication-0.9.17.1 app/views/users/index.html.erb
tkh_authentication-0.9.17 app/views/users/index.html.erb
tkh_authentication-0.9.16 app/views/users/index.html.erb
tkh_authentication-0.9.15 app/views/users/index.html.erb