mirror of
https://github.com/openfoodfoundation/openfoodnetwork
synced 2026-03-06 02:51:34 +00:00
Merge pull request #13958 from arunguleria/13864-remove-variants-dead-features
13864-Remove dead feature to re-arrange variants
This commit is contained in:
@@ -4,25 +4,21 @@
|
||||
|
||||
#new_variant
|
||||
|
||||
%table.index.sortable{"data-sortable-link" => update_positions_admin_product_variants_path(@product)}
|
||||
%table.index
|
||||
%colgroup
|
||||
%col{style: "width: 5%"}/
|
||||
%col{style: "width: 25%"}/
|
||||
%col{style: "width: 20%"}/
|
||||
%col{style: "width: 20%"}/
|
||||
%col{style: "width: 15%"}/
|
||||
%col{style: "width: 15%"}/
|
||||
%col{style: "width: 25%"}/
|
||||
%col{style: "width: 25%"}/
|
||||
%col{style: "width: 25%"}/
|
||||
%thead
|
||||
%tr
|
||||
%th{colspan: "2"}= t('.options')
|
||||
%th= t('.price')
|
||||
%th= t('.sku')
|
||||
%th= t('.options')
|
||||
%th{ style: 'text-align: center;' }= t('.price')
|
||||
%th{ style: 'text-align: center;' }= t('.sku')
|
||||
%th.actions
|
||||
%tbody
|
||||
- @variants.each do |variant|
|
||||
%tr{id: spree_dom_id(variant), class: cycle('odd', 'even'), style: "#{"color:red;" if variant.deleted? }" }
|
||||
%td.no-border
|
||||
%span.handle
|
||||
%td= variant.full_name
|
||||
%td.align-center= variant.display_price.to_html
|
||||
%td.align-center= variant.sku
|
||||
|
||||
@@ -69,11 +69,7 @@ Spree::Core::Engine.routes.draw do
|
||||
end
|
||||
end
|
||||
|
||||
resources :variants do
|
||||
collection do
|
||||
post :update_positions
|
||||
end
|
||||
end
|
||||
resources :variants
|
||||
end
|
||||
|
||||
get '/variants/search', :to => "variants#search", :as => :search_variants
|
||||
|
||||
Reference in New Issue
Block a user