html_ruby.erb 518 B

1234567891011121314151617181920212223242526
  1. <h1>Listing Books</h1>
  2. <table>
  3. <tr>
  4. <th>Title</th>
  5. <th>Summary</th>
  6. <th></th>
  7. <th></th>
  8. <th></th>
  9. </tr>
  10. <% @books.each do |book| %>
  11. <tr>
  12. <%# comment %>
  13. <td><%= book.title %></td>
  14. <td><%= book.content %></td>
  15. <td><%= link_to 'Show', book %></td>
  16. <td><%= link_to 'Edit', edit_book_path(book) %></td>
  17. <td><%= link_to 'Remove', book, :confirm => 'Are you sure?', :method => :delete %></td>
  18. </tr>
  19. <% end %>
  20. </table>
  21. <br />
  22. <%= link_to 'New book', new_book_path %>