<%= render :partial => 'image' -%>
<%= render :partial => 'thumbnails', :locals => {:product => @product} -%>
<% form_for :product, :url => {:controller => :cart, :action => :add} do |f| %> <% if @product.variants? %> <% else %> /> <% end%> <% end %>
<%= @product.name %>
<%= @product.description %>
<%="Price: #{product_price(@product)}" if product_price(@product) %>
Variants:
    <% @product.variants.each do |v| %> <% next if v.option_values.empty? %>
  • /> <%= variant_options v%> <% if variant_price_diff v %> <%= variant_price_diff v %> <% end %>
  • <% end%>
<%= submit_tag 'Add To Cart' %>