Sha256: 8d2a8211c4ff3d49d1e0acde2c2118d8ae732831c4bf8c8c141d73112af25f2c

Contents?: true

Size: 1.13 KB

Versions: 1

Compression:

Stored size: 1.13 KB

Contents

<div class="page-header">
  <h1>
    <%= @item_section.title %>
  </h1>
  <% if current_user.role == 'admin' %>
      <%= link_to "Edit #{@item_section.title}", cavy_edit_item_section_path(@item_section.id), class: 'button primary small' %>
  <% end %>
</div>
<table class="table table-striped">
  <thead>
  <th>Title</th>
  <th>Parameters</th>
  <th></th>
  <% if current_user.dev_team? %>
      <th></th>
  <% end %>
  </thead>
  <tbody>
  <% @item_groups.each do |item_group| %>
      <tr>
        <td>
          <%= link_to item_group.title, cavy_item_group_path(item_group.id) %>
        </td>
        <td>
          <%= item_group.params.join(', ') if item_group.params %>
        </td>
        <td>
          <%= link_to 'Edit', admin_edit_item_group_path(item_group.id), class: 'button primary small' %>
        </td>
        <% if current_user.dev_team? %>
            <td>
              <%= link_to 'Destroy', cavy_delete_item_group_path(item_group.id), class: 'button alert small', method: :delete, data: {confirm: 'Are you sure?'}, id: "delete-#{item_group.id}" %>
            </td>
        <% end %>
      </tr>
  <% end %>
  </tbody>
</table>

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
cavy-0.1.0.beta1 app/views/cavy/item_sections/show.html.erb