Sha256: ee367b5411a2da01521a84cfb67a69c7e4e5244608a01386ae0ae7c48c73c210

Contents?: true

Size: 1.64 KB

Versions: 6

Compression:

Stored size: 1.64 KB

Contents

<% content_for :page_title do %>
  <%= Spree.t(:promotions) %>
<% end %>

<% content_for :page_actions do %>
  <li>
    <%= button_link_to Spree.t(:new_promotion), spree.new_admin_promotion_path, :icon => 'icon-plus' %>
  </li>
<% end %>

<% unless @promotions.any? %>
  <div class="no-objects-found">
    <%= Spree.t(:no_promotions_found) %>.
    <%= link_to Spree.t(:add_one), spree.new_admin_promotion_path %>!
  </div>
<% else %>
  <table class="index">
    <colgroup>
      <col style="width: 20%">
      <col style="width: 10%">
      <col style="width: 35%">
      <col style="width: 10%">
      <col style="width: 15%">
      <col style="width: 10%">
    </colgroup>
    <thead>
      <tr>
        <th><%= Spree.t(:name) %></th>
        <th><%= Spree.t(:code) %></th>
        <th><%= Spree.t(:description) %></th>
        <th><%= Spree.t(:usage_limit) %></th>
        <th><%= Spree.t(:expiration) %></th>
        <th class="actions"></th>
      </tr>
    </thead>
    <tbody>
      <% @promotions.each do |promotion| %>
        <tr id="<%= spree_dom_id promotion %>" class="<%= cycle('odd', 'even')%>">
          <td><%= promotion.name %></td>
          <td class="align-center"><%= promotion.code %></td>
          <td><%= promotion.description %></td>
          <td class="align-center"><%= promotion.usage_limit %></td>
          <td class="align-center"><%= promotion.expires_at.to_date.to_s(:short_date) if promotion.expires_at %></td>
          <td class="actions">
            <%= link_to_edit promotion, :no_text => true %>
            <%= link_to_delete promotion, :no_text => true %>
          </td>
        </tr>
      <% end %>
    </tbody>
  </table>
<% end %>

Version data entries

6 entries across 6 versions & 1 rubygems

Version Path
spree_backend-2.0.4 app/views/spree/admin/promotions/index.html.erb
spree_backend-2.0.3 app/views/spree/admin/promotions/index.html.erb
spree_backend-2.0.2 app/views/spree/admin/promotions/index.html.erb
spree_backend-2.0.1 app/views/spree/admin/promotions/index.html.erb
spree_backend-2.0.0 app/views/spree/admin/promotions/index.html.erb
spree_backend-2.0.0.rc1 app/views/spree/admin/promotions/index.html.erb