Sha256: c4580e98a19c74479b48bb9c7e7a3e104ba7550e3be12548f233c749a7a68d66

Contents?: true

Size: 897 Bytes

Versions: 3

Compression:

Stored size: 897 Bytes

Contents

<%% title "<%= plural_name.titleize %>" %>

<table>
  <tr>
  <%- for attribute in attributes -%>
    <th><%= attribute.human_name.titleize %></th>
  <%- end -%>
  </tr>
  <%% for <%= instance_name %> in @<%= instances_name %> %>
    <tr>
    <%- for attribute in attributes -%>
      <td><%%= <%= instance_name %>.<%= attribute.name %> %></td>
    <%- end -%>
    <%- if action? :show -%>
      <td><%%= link_to "Show", <%= item_path %> %></td>
    <%- end -%>
    <%- if action? :edit -%>
      <td><%%= link_to "Edit", <%= item_path :action => :edit %> %></td>
    <%- end -%>
    <%- if action? :destroy -%>
      <td><%%= link_to "Destroy", <%= item_path %>, :confirm => 'Are you sure?', :method => :delete %></td>
    <%- end -%>
    </tr>
  <%% end %>
</table>

<%- if action? :new -%>
<p><%%= link_to "New <%= singular_name.titleize %>", <%= item_path :action => :new %> %></p>
<%- end -%>

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
adhoc-generators-0.0.5 lib/generators/adhoc/portfolio/templates/views/index.html.erb
adhoc-generators-0.0.4 lib/generators/adhoc/portfolio/templates/views/index.html.erb
adhoc-generators-0.0.3 lib/generators/adhoc/portfolio/templates/views/index.html.erb