app/views/admin/variants/index.html.erb in spree-0.8.5 vs app/views/admin/variants/index.html.erb in spree-0.9.0
- old
+ new
@@ -14,11 +14,11 @@
<th><%= t("action") %></th>
</tr>
<% @variants.each do |variant| %>
<!-- you can skip variant with no options: that's just the default variant that all products have -->
<% next if variant.option_values.empty? %>
- <tr <%= 'style="color:red;"' unless variant.deleted_at.nil? %>>
+ <tr id="<%= dom_id(variant) %>" <%= 'style="color:red;"' unless variant.deleted_at.nil? %>>
<td><%= variant_options variant %></td>
<td><%= variant.price %></td>
<td><%= variant.sku %></td>
<% Variant.additional_fields.select{|f| f[:only].nil? || f[:only].include?(:variant) }.each do |field| %>
<td><%= variant[field[:name].gsub(" ", "_").downcase] %></td>
@@ -29,10 +29,10 @@
<%= link_to_delete(variant) if variant.deleted_at.nil? %>
</td>
</tr>
<% end %>
- <% unless @product.variants? %>
+ <% unless @product.has_variants? %>
<tr><td colspan="5"><%= t("none") %>.</td></tr>
<% end %>
</table>
<% if @product.options.empty? %>