mirror of
https://github.com/openfoodfoundation/openfoodnetwork
synced 2026-01-24 20:36:49 +00:00
Hiding 'Back to Cart' and 'Back to Store' buttons on completed orders when distributor does not match cart
This commit is contained in:
@@ -1,13 +1,16 @@
|
||||
.row
|
||||
.columns.small-12.medium-3
|
||||
- if current_order.andand.line_items.present?
|
||||
= link_to spree.cart_path, :class => "button expand" do
|
||||
%i.ofn-i_008-caret-left
|
||||
= t(:order_back_to_cart)
|
||||
- if current_order.andand.distributor == @order.distributor
|
||||
- if current_order.line_items.present?
|
||||
= link_to spree.cart_path, :class => "button expand" do
|
||||
%i.ofn-i_008-caret-left
|
||||
= t(:order_back_to_cart)
|
||||
- else
|
||||
= link_to main_app.shop_path, :class => "button expand" do
|
||||
%i.ofn-i_008-caret-left
|
||||
= t(:order_back_to_store)
|
||||
- else
|
||||
= link_to main_app.shop_path, :class => "button expand" do
|
||||
%i.ofn-i_008-caret-left
|
||||
= t(:order_back_to_store)
|
||||
|
||||
- if order.changes_allowed?
|
||||
.columns.show-for-medium-up.medium-3
|
||||
.columns.small-12.medium-3
|
||||
|
||||
Reference in New Issue
Block a user