From 8f174b130861432753e75d0e9edf2b7dd21b3d77 Mon Sep 17 00:00:00 2001 From: Matt-Yorkley <9029026+Matt-Yorkley@users.noreply.github.com> Date: Tue, 11 Sep 2018 11:43:38 +0100 Subject: [PATCH] Apply ship shortcut override --- .../admin/orders/index/add_ship_shortcut.html.haml.deface | 6 ------ app/views/spree/admin/orders/index.html.haml | 3 +++ 2 files changed, 3 insertions(+), 6 deletions(-) delete mode 100644 app/overrides/spree/admin/orders/index/add_ship_shortcut.html.haml.deface diff --git a/app/overrides/spree/admin/orders/index/add_ship_shortcut.html.haml.deface b/app/overrides/spree/admin/orders/index/add_ship_shortcut.html.haml.deface deleted file mode 100644 index a0ac8a7266..0000000000 --- a/app/overrides/spree/admin/orders/index/add_ship_shortcut.html.haml.deface +++ /dev/null @@ -1,6 +0,0 @@ -/ insert_bottom "[data-hook='admin_orders_index_row_actions']" --# See also: app/overrides/add_capture_order_shortcut.rb - -- if order.ready_to_ship? - - # copied from backend/app/views/spree/admin/payments/_list.html.erb - = link_to_with_icon "icon-road", t('admin.orders.index.ship'), fire_admin_order_url(order, :e => 'ship'), :method => :put, :no_text => true, :data => {:action => 'ship', :confirm => t(:are_you_sure)} diff --git a/app/views/spree/admin/orders/index.html.haml b/app/views/spree/admin/orders/index.html.haml index 1bb334e4ad..adfe35ee38 100644 --- a/app/views/spree/admin/orders/index.html.haml +++ b/app/views/spree/admin/orders/index.html.haml @@ -93,6 +93,9 @@ %td.align-center= order.display_total.to_html %td.actions.align-center{"data-hook" => "admin_orders_index_row_actions"} = link_to_edit_url edit_admin_order_path(order), :title => "admin_edit_#{dom_id(order)}", :no_text => true + - if order.ready_to_ship? + - # copied from backend/app/views/spree/admin/payments/_list.html.erb + = link_to_with_icon "icon-road", t('admin.orders.index.ship'), fire_admin_order_url(order, :e => 'ship'), :method => :put, :no_text => true, :data => {:action => 'ship', :confirm => t(:are_you_sure)} - else .no-objects-found = t(:no_orders_found)