mirror of
https://github.com/openfoodfoundation/openfoodnetwork
synced 2026-02-26 01:33:22 +00:00
Move override for cart line item into existing view replacement
This commit is contained in:
@@ -1,5 +0,0 @@
|
||||
Deface::Override.new(:virtual_path => "spree/orders/_line_item",
|
||||
:replace => "[data-hook='cart_item_description']",
|
||||
:partial => "spree/orders/cart_item_description",
|
||||
:name => "cart_item_description",
|
||||
:original => 'ce2b7ddab2a6a13b25159ea18f6ab50991409d3e')
|
||||
@@ -1,7 +0,0 @@
|
||||
%td{'data-hook' => "cart_item_description"}
|
||||
%h4= variant.product.name
|
||||
= variant.options_text
|
||||
- if @order.insufficient_stock_lines.include? line_item
|
||||
%span.out-of-stock
|
||||
= variant.in_stock? ? t(:insufficient_stock, :on_hand => variant.on_hand) : t(:out_of_stock)
|
||||
%br/
|
||||
@@ -5,14 +5,13 @@
|
||||
- else
|
||||
= link_to image_tag(variant.images.first.attachment.url(:small)), variant.product
|
||||
|
||||
%td.cart-item-description{"data-hook" => "cart_item_description"}
|
||||
%h4= link_to variant.product.name, product_path(variant.product)
|
||||
%td.cart-item-description{'data-hook' => "cart_item_description"}
|
||||
%h4= variant.product.name
|
||||
= variant.options_text
|
||||
- if @order.insufficient_stock_lines.include? line_item
|
||||
%span.out-of-stock
|
||||
= variant.in_stock? ? t(:insufficient_stock, :on_hand => variant.on_hand) : t(:out_of_stock)
|
||||
%br
|
||||
= line_item_description(variant)
|
||||
%br/
|
||||
|
||||
%td.cart-item-price{"data-hook" => "cart_item_price"}
|
||||
= line_item.single_money.to_html
|
||||
|
||||
Reference in New Issue
Block a user