Skip to content

Instantly share code, notes, and snippets.

@darui00kara
Created July 1, 2015 01:41
Show Gist options
  • Save darui00kara/d03c84d4c8b4890dec29 to your computer and use it in GitHub Desktop.
Save darui00kara/d03c84d4c8b4890dec29 to your computer and use it in GitHub Desktop.
<h2>Listing users</h2>
<table class="table">
<thead>
<tr>
<th>Name</th>
<th>Email</th>
<th>Password</th>
<th></th>
</tr>
</thead>
<tbody>
<%= for user <- @users do %>
<tr>
<td><%= user.name %></td>
<td><%= user.email %></td>
<td><%= user.password %></td>
<td class="text-right">
<%= link "Show", to: user_path(@conn, :show, user), class: "btn btn-default btn-xs" %>
<%= link "Edit", to: user_path(@conn, :edit, user), class: "btn btn-default btn-xs" %>
<%= link "Delete", to: user_path(@conn, :delete, user), method: :delete, class: "btn btn-danger btn-xs" %>
</td>
</tr>
<% end %>
</tbody>
</table>
<%= link "New user", to: user_path(@conn, :new) %>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment