Sha256: bb9be94af1cfda79f2541bf3b7b1bdb797eead495df71078ade366a7ea426764

Contents?: true

Size: 1.03 KB

Versions: 10

Compression:

Stored size: 1.03 KB

Contents

<%% add_title '<%= plural_table_name.titleize %>' %>

<table class="table table-bordered">
  <thead>
  <tr>
<% attributes.reject(&:password_digest?).each do |attribute| -%>
    <th><%= attribute.human_name %></th>
<% end -%>
    <th colspan="3"></th>
  </tr>
  </thead>

  <tbody>
  <%% @<%= plural_table_name %>.each do |<%= singular_table_name %>| %>
  <tr>
<% attributes.reject(&:password_digest?).each do |attribute| -%>
    <td><%%= <%= singular_table_name %>.<%= attribute.name %> %></td>
<% end -%>
    <td><%%= link_to :show.l, <%= singular_table_name %>, class: 'btn btn-success' %></td>
    <td><%%= link_to :edit.l, edit_<%= singular_table_name %>_path(<%= singular_table_name %>), class: 'btn btn-info' %></td>
    <td><%%= link_to :destroy.l, <%= singular_table_name %>, method: :delete, class: 'btn btn-danger', data: { confirm: :are_you_sure.l } %></td>
  </tr>
  <%% end %>
  </tbody>
</table>

<p>
  <%%= link_to :new.l(name: '<%= singular_table_name.titleize %>'), new_<%= singular_table_name %>_path, class: 'btn btn-primary' %>
</p>

Version data entries

10 entries across 10 versions & 1 rubygems

Version Path
bootstrap_leather-0.10.14 lib/templates/erb/scaffold/index.html.erb
bootstrap_leather-0.10.13 lib/templates/erb/scaffold/index.html.erb
bootstrap_leather-0.10.11 lib/templates/erb/scaffold/index.html.erb
bootstrap_leather-0.10.10 lib/templates/erb/scaffold/index.html.erb
bootstrap_leather-0.10.9 lib/templates/erb/scaffold/index.html.erb
bootstrap_leather-0.10.8 lib/templates/erb/scaffold/index.html.erb
bootstrap_leather-0.10.7 lib/templates/erb/scaffold/index.html.erb
bootstrap_leather-0.10.6 lib/templates/erb/scaffold/index.html.erb
bootstrap_leather-0.10.5 lib/templates/erb/scaffold/index.html.erb
bootstrap_leather-0.10.4 lib/templates/erb/scaffold/index.html.erb