24 lines
561 B
Plaintext
24 lines
561 B
Plaintext
|
<h1>Users</h1>
|
||
|
|
||
|
<table class="table">
|
||
|
<thead>
|
||
|
<tr>
|
||
|
<th>Email</th>
|
||
|
<th>Admin</th>
|
||
|
<th>Actions</th>
|
||
|
</tr>
|
||
|
</thead>
|
||
|
<tbody>
|
||
|
<% @users.each do |user| %>
|
||
|
<tr>
|
||
|
<td><%= user.email %></td>
|
||
|
<td><%= user.admin? ? 'Yes' : 'No' %></td>
|
||
|
<td>
|
||
|
<%= link_to 'Edit', edit_user_path(user), class: 'btn btn-info' %>
|
||
|
<%= link_to 'Delete', user_path(user), method: :delete, data: { confirm: 'Are you sure?' }, class: 'btn btn-danger' %>
|
||
|
</td>
|
||
|
</tr>
|
||
|
<% end %>
|
||
|
</tbody>
|
||
|
</table>
|