Sha256: f54b144302f948f3a3d57e9f5522ccbbeb17b0763070c07c8c2307e4da0b2177

Contents?: true

Size: 766 Bytes

Versions: 7

Compression:

Stored size: 766 Bytes

Contents

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

<table>
  <tr>
<% for attribute in attributes -%>
    <th><%= attribute.column.human_name %></th>
<% end -%>
  </tr>

<%% @<%= plural_name %>.each do |<%= singular_name %>| %>
  <tr>
<% for attribute in attributes -%>
    <td><%%=h <%= singular_name %>.<%= attribute.name %> %></td>
<% end -%>
    <td><%%= link_to 'Show', <%= singular_name %>_path(<%= singular_name %>.key) %></td>
    <td><%%= link_to 'Edit', edit_<%= singular_name %>_path(<%= singular_name %>.key) %></td>
    <td><%%= link_to 'Destroy', <%= singular_name %>_path(<%= singular_name %>.key), :confirm => 'Are you sure?', :method => :delete %></td>
  </tr>
<%% end %>
</table>

<br />

<%%= link_to 'New <%= singular_name %>', new_<%= singular_name %>_path %>

Version data entries

7 entries across 7 versions & 1 rubygems

Version Path
datamapper4rails-0.5.2 generators/datamapper_scaffold/templates/view_index.html.erb
datamapper4rails-0.5.1 generators/datamapper_scaffold/templates/view_index.html.erb
datamapper4rails-0.5.0 generators/datamapper_scaffold/templates/view_index.html.erb
datamapper4rails-0.4.0 generators/datamapper_scaffold/templates/view_index.html.erb
datamapper4rails-0.3.2 generators/datamapper_scaffold/templates/view_index.html.erb
datamapper4rails-0.3.1 generators/datamapper_scaffold/templates/view_index.html.erb
datamapper4rails-0.3.0 generators/datamapper_scaffold/templates/view_index.html.erb