Sha256: 2cd7688d122980834a52c9ad6f66eedf28c54adb7140a4a39bc508b63d37e67e
Contents?: true
Size: 1.07 KB
Versions: 1
Compression:
Stored size: 1.07 KB
Contents
<% variants = @product.variants_and_option_values_for(current_pricing_options) %> <% if variants.any? %> <section class="product-variants" id="product-variants"> <h2 class="product-variants__title"> <%= t('spree.variants') %> </h2> <ul class="product-variants__list"> <% variants.each_with_index do |variant, index| %> <li> <%= radio_button_tag( 'variant_id', variant.id, index == 0, 'data-price' => variant.price_for(current_pricing_options) ) %> <%= label_tag "variant_id_#{ variant.id }" do %> <%= variant_options variant %> <% if variant_price variant %> <span class="price diff"><%= variant_price variant %></span> <% end %> <% unless variant.can_supply? %> <span class="out-of-stock"><%= t('spree.out_of_stock') %></span> <% end %> <% end %> </li> <% end %> </ul> </section> <% else %> <%= hidden_field_tag "variant_id", @product.master.id %> <% end %>
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
solidus_starter_frontend-0.1.0 | app/views/spree/components/products/_product_variants.html.erb |