Skip to content

Commit

Permalink
Change "product" url to "product variant" url in cart line item (Shop…
Browse files Browse the repository at this point in the history
…ify#475)

* Change product url to product variant url in cart line item

* replace product url to variant url in Ordere teemplatee
  • Loading branch information
tauthomas01 authored Aug 25, 2021
1 parent 59ad9b4 commit f034507
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions sections/main-cart-items.liquid
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@
<tr class="cart-item" id="CartItem-{{ item.index | plus: 1 }}">
<td class="cart-item__media">
{% if item.image %}
<a href="{{ item.product.url }}">
<a href="{{ item.url }}">
<img class="cart-item__image"
src="{{ item.image | img_url: '150x' }}"
alt="{{ item.image.alt | escape }}"
Expand All @@ -63,7 +63,7 @@
<p class="caption-with-letter-spacing light">{{ item.product.vendor }}</p>
{%- endif -%}

<a href="{{ item.product.url }}" class="cart-item__name break">{{ item.product.title | escape }}</a>
<a href="{{ item.url }}" class="cart-item__name break">{{ item.product.title | escape }}</a>

{%- if item.product.has_only_default_variant == false or item.properties.size != 0 or item.selling_plan_allocation != nil -%}
<dl>
Expand Down
4 changes: 2 additions & 2 deletions templates/customers/order.liquid
Original file line number Diff line number Diff line change
Expand Up @@ -44,8 +44,8 @@
data-label="{{ 'customer.order.product' | t }}"
>
<div>
{%- if line_item.product.url != blank -%}
<a href="{{ line_item.product.url }}">{{ line_item.title }}</a>
{%- if line_item.url != blank -%}
<a href="{{ line_item.url }}">{{ line_item.title }}</a>
{%- else -%}
<p>{{ line_item.title }}</p>
{%- endif -%}
Expand Down

0 comments on commit f034507

Please sign in to comment.