view app/views/pastes/index.html.erb @ 7:3a1f6c2e195d

Added raw paste view.
author Edho Arief <edho@myconan.net>
date Sun, 26 Aug 2012 11:39:07 -0700
parents 42de15334db1
children
line wrap: on
line source

<h1>Listing pastes</h1>

<table>
  <tr>
    <th>Id</th>
    <th>Paste</th>
    <th></th>
    <th></th>
  </tr>

<% @pastes.each do |paste| %>
  <tr>
    <td><%= link_to paste.id, paste %></td>
    <td><%= paste.paste %></td>
    <td><%= link_to 'Edit', edit_paste_path(paste) %></td>
    <td><%= link_to 'Destroy', paste, :method => :delete, :data => { :confirm => 'Are you sure?' } %></td>
  </tr>
<% end %>
</table>

<br />

<%= link_to 'New Paste', new_paste_path %>