<h1>Users</h1>
<table class="table table-condensed">
  <thead>
    <tr>
      <th>ID</th>
      <th>Email</th>
      <th>Role</th>
      <th>School</th>
      <th>Sign in count</th>
      <th>Access locked</th>
      <th></th>
    </tr>
  </thead>

  <tbody>
    <% @users.each do |user| %>
      <tr>
          <td><%= user.id %></td>
          <td><%= user.email %></td>
          <td><%= user.role.titleize %></td>
          <td><%= link_to user.school.name, school_path(user.school) if user.school %></td>
          <td><%= user.sign_in_count %></td>
          <td><%= user.access_locked? ? 'Y' : '' %></td>
          <td>
            <div class="btn-group">
              <%= link_to 'Edit', edit_user_path(user), class: 'btn btn-primary btn-sm' %>
              <%= link_to 'Delete', user_path(user), method: :delete, data: { confirm: 'Are you sure?' }, class: 'btn btn-danger btn-sm' %>
            </div>
          </td>
      </tr>
    <% end %>
  </tbody>
</table>

<%= link_to 'New User', new_user_path, class: 'btn btn-primary' %>

<h1>Users</h1>
<table class="table table-condensed">
  <thead>
    <tr>
      <th>ID</th>
      <th>Name</th>
      <th>Email</th>
      <th>Role</th>
      <th>School</th>
      <th>Sign in count</th>
      <th>Access locked</th>
      <th></th>
    </tr>
  </thead>

  <tbody>
    <% @users.each do |user| %>
      <tr>
          <td><%= user.id %></td>
          <td><%= user.name %></td>
          <td><%= user.email %></td>
          <td><%= user.role.titleize %></td>
          <td><%= link_to user.school.name, school_path(user.school) if user.school %></td>
          <td><%= user.sign_in_count %></td>
          <td><%= user.access_locked? ? 'Y' : '' %></td>
          <td>
            <div class="btn-group">
              <%= link_to 'Edit', edit_user_path(user), class: 'btn btn-primary btn-sm' %>
              <%= link_to 'Delete', user_path(user), method: :delete, data: { confirm: 'Are you sure?' }, class: 'btn btn-danger btn-sm' %>
            </div>
          </td>
      </tr>
    <% end %>
  </tbody>
</table>

<%= link_to 'New User', new_user_path, class: 'btn btn-primary' %>

Add names to user list
Add names to user list
