Sha256: b223aa3ece1d615bab5a5f408d1d8e85c87a4639dde9a18e13bca523cf464ea7
Contents?: true
Size: 1.72 KB
Versions: 5
Compression:
Stored size: 1.72 KB
Contents
<% content_for :page_title do %> <%= Spree.t(:listing_favorite_products) %> <% end %> <%= render :partial => 'spree/admin/shared/product_sub_menu' %> <%= paginate @favorite_products %> <% if @favorite_products.any? %> <table class="index" id="listing_products"> <colgroup> <col style="width: 15%;"> <col style="width: 10%;"> <col style="width: 38%;"> <col style="width: 10%;"> <col style="width: 17%;"> <col style="width: 10%;"> </colgroup> <thead> <tr data-hook="admin_products_index_headers"> <th><%= Spree.t(:sku) %></th> <th colspan="2"><%= sort_link @search, :name, Spree.t(:name) %></th> <th><%= sort_link @search, :master_default_price_amount, Spree.t(:master_price) %></th> <th><%= sort_link @search, 'favorite_users_count', 'Favorite Users' %></th> </tr> </thead> <tbody> <% @favorite_products.each do |product| %> <tr <%= "style='color: red;'" if product.deleted? %> id="<%= spree_dom_id product %>" data-hook="admin_products_index_rows" class="<%= cycle('odd', 'even') %>"> <td class="align-center"><%= product.sku rescue '' %></td> <td class="align-center"><%= mini_image(product) %></td> <td><%= link_to product.try(:name), edit_admin_product_path(product) %></td> <td class="align-center"><%= product.display_price.to_html rescue '' %></td> <td class='align-center'><%= link_to product.favorite_users.count, users_admin_favorite_product_path(:id => product.id) %></td> </tr> <% end %> </tbody> </table> <% else %> <div class="no-objects-found"> <%= Spree.t(:no_results) %> </div> <% end %> <%= paginate @favorite_products %>
Version data entries
5 entries across 5 versions & 1 rubygems