Sha256: bc729ab46d5e03064d92b19b44f136bf16eff6d5326f31da67bf13a98db27fa0

Contents?: true

Size: 1.06 KB

Versions: 7

Compression:

Stored size: 1.06 KB

Contents

<h1>Listing <%= plural_name %></h1>

<table>
  <tr>
  <%% for column in <%= model_name %>.content_columns %>
    <th><%%= column.human_name %></th>
  <%% end %>
  </tr>
  
<%% for <%= singular_name %> in @<%= plural_name %> %>
  <tr>
  <%% for column in <%= model_name %>.content_columns %>
    <td><%%=h <%= singular_name %>.send(column.name) %></td>
  <%% end %>
    <td><%%= link_to 'Show', :action => 'show<%= suffix %>', :id => <%= singular_name %> %></td>
    <td><%%= link_to 'Edit', :action => 'edit<%= suffix %>', :id => <%= singular_name %> %></td>
    <td><%%= link_to 'Destroy', { :action => 'destroy<%= suffix %>', :id => <%= singular_name %> }, :confirm => 'Are you sure?', :post => true %></td>
  </tr>
<%% end %>
</table>

<%%= link_to 'Previous page', { :page => @<%= singular_name %>_pages.current.previous } if @<%= singular_name %>_pages.current.previous %>
<%%= link_to 'Next page', { :page => @<%= singular_name %>_pages.current.next } if @<%= singular_name %>_pages.current.next %> 

<br />

<%%= link_to 'New <%= singular_name %>', :action => 'new<%= suffix %>' %>

Version data entries

7 entries across 7 versions & 1 rubygems

Version Path
rails-1.1.0 lib/rails_generator/generators/components/scaffold/templates/view_list.rhtml
rails-1.1.1 lib/rails_generator/generators/components/scaffold/templates/view_list.rhtml
rails-1.1.2 lib/rails_generator/generators/components/scaffold/templates/view_list.rhtml
rails-1.1.3 lib/rails_generator/generators/components/scaffold/templates/view_list.rhtml
rails-1.1.4 lib/rails_generator/generators/components/scaffold/templates/view_list.rhtml
rails-1.1.5 lib/rails_generator/generators/components/scaffold/templates/view_list.rhtml
rails-1.1.6 lib/rails_generator/generators/components/scaffold/templates/view_list.rhtml