Create a gist now

Instantly share code, notes, and snippets.

What would you like to do?
<% if @quotes.any? %>
<table class="table table-striped">
<% @quotes.each do |quote| %>
<td><%= quote.content %></td>
<td><%= link_to 'Excluir', quote_path(quote), method: :delete, confirm: 'Tem certeza?', class: 'btn' %></td>
<% end %>
<% else %>
<div class="well">Nenhuma frase cadastrada.</div>
<% end %>
<%= link_to 'Cadastre uma frase', new_quote_path, class: 'btn btn-primary' %>
<%= link_to 'Voltar ao início', root_path, class: 'btn btn-primary' %>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment