% @products = (@templates if type.eql?('templates')) || (@extensions if type.eql?('extensions')) %>
<% cache [ 'product list', expires_in: 60.seconds ] do %>
<% @products.each do |product| %>
<%= link_to "", product, :class=> "details-link" %>
<%= placeholdit_image_tag (type == 'templates' ? "256x180" : '100x100'), background_color: "#3f3f3f" %>
<%= content_tag(:h2, (link_to product.title, product), :class => "item-title") %>
<%= content_tag(:p, (link_to "Developer: #{product.author}"), :class => "developer-title") %>
<%= render :partial => "shared/stars_rank" if type != 'templates' %>
<%= content_tag(:p, product.price.nil?.eql?(true) ? 'Free' : product.price, :class => "price-container") %>
<% end %>
<% end %>