Sha256: 17874c3e1f7f13f5f7ea0464037ea6a3a6e5e0c3917d7da1b6712ac4c47110cb

Contents?: true

Size: 701 Bytes

Versions: 5

Compression:

Stored size: 701 Bytes

Contents

<h2><%= table_name %></h2>

<%% if @<%= table_name %>.count > 0 %>
<table id='table:<%%= controller_name %>' class='resource_table'>
  <thead>
    <% attributes.each do |attribute| -%>
      <th><%= attribute.name.humanize %></th>
    <% end -%>
  </thead>

  <tbody>
    <%% @<%= table_name %>.each do |<%= table_name[0] %>| %>
      <%%= content_tag_for(:tr, <%= table_name[0] %>) do %>
        <% attributes.each do |attribute| -%>
          <td><%%= <%= table_name[0] %>.<%= attribute.name %> %></td>
        <% end -%>
      <%% end %>
    <%% end %>
  </tbody>
</table>
<%% end %>

<div class='model-actions'>
  <%%= link_to 'New <%= name %>', new_manifest_<%= name.underscore %>_path %>
</div>

Version data entries

5 entries across 5 versions & 1 rubygems

Version Path
manifest-rails-0.2.8 lib/generators/manifest/data_type/templates/index.html.erb
manifest-rails-0.2.7 lib/generators/manifest/data_type/templates/index.html.erb
manifest-rails-0.2.6 lib/generators/manifest/data_type/templates/index.html.erb
manifest-rails-0.2.5 lib/generators/manifest/data_type/templates/index.html.erb
manifest-rails-0.2.4 lib/generators/manifest/data_type/templates/index.html.erb