Skip to content

Commit

Permalink
Merge pull request #2977 from aitbw/nebulab/improve-track-inventory-ux
Browse files Browse the repository at this point in the history
Use Spree::Variant#should_track_inventory? to disable 'Count on hand' input
  • Loading branch information
kennyadsl authored Nov 28, 2018
2 parents 318ff36 + 476dd26 commit ceae80f
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@
</colgroup>
<% variant.stock_items.each do |item| %>
<% if @stock_item_stock_locations.include?(item.stock_location) %>
<tr class="js-edit-stock-item stock-item-edit-row" data-variant-id="<%= variant.id %>" data-stock-item="<%= item.to_json %>" data-stock-location-name="<%= item.stock_location.name %>" data-track-inventory="<%= variant.track_inventory %>">
<tr class="js-edit-stock-item stock-item-edit-row" data-variant-id="<%= variant.id %>" data-stock-item="<%= item.to_json %>" data-stock-location-name="<%= item.stock_location.name %>" data-track-inventory="<%= variant.should_track_inventory? %>">
<%# This is rendered in JS %>
</tr>
<% end %>
Expand Down

0 comments on commit ceae80f

Please sign in to comment.