fix product-card
This commit is contained in:
@@ -284,24 +284,6 @@
|
|||||||
</h3>
|
</h3>
|
||||||
</div>
|
</div>
|
||||||
<div class="card__badge {{ settings.badge_position }}">
|
<div class="card__badge {{ settings.badge_position }}">
|
||||||
{%- if card_product.available == false -%}
|
|
||||||
{% unless show_sold_out_badge %}
|
|
||||||
<span
|
|
||||||
id="NoMediaStandardBadge-{{ section_id }}-{{ card_product.id }}"
|
|
||||||
class="badge dbtfy-sold-out-badge"
|
|
||||||
>
|
|
||||||
{%- if settings.sold_out_badge_text != blank -%}
|
|
||||||
{{- settings.sold_out_badge_text -}}
|
|
||||||
{%- else -%}
|
|
||||||
{{- 'products.product.sold_out' | t -}}
|
|
||||||
{%- endif -%}
|
|
||||||
</span>
|
|
||||||
{% endunless %}
|
|
||||||
{%- elsif card_product.compare_at_price > card_product.price
|
|
||||||
and card_product.available
|
|
||||||
and show_sale_badge == false
|
|
||||||
-%}
|
|
||||||
{% if settings.dbtfy_discount_saved and section.settings.custom_badge_label == blank %}
|
|
||||||
{% liquid
|
{% liquid
|
||||||
assign card_product_compare_at_price = card_product.compare_at_price
|
assign card_product_compare_at_price = card_product.compare_at_price
|
||||||
assign card_product_price = card_product.price
|
assign card_product_price = card_product.price
|
||||||
@@ -359,6 +341,24 @@
|
|||||||
end Yagi app code
|
end Yagi app code
|
||||||
endcomment
|
endcomment
|
||||||
%}
|
%}
|
||||||
|
{%- if card_product.available == false -%}
|
||||||
|
{% unless show_sold_out_badge %}
|
||||||
|
<span
|
||||||
|
id="NoMediaStandardBadge-{{ section_id }}-{{ card_product.id }}"
|
||||||
|
class="badge dbtfy-sold-out-badge"
|
||||||
|
>
|
||||||
|
{%- if settings.sold_out_badge_text != blank -%}
|
||||||
|
{{- settings.sold_out_badge_text -}}
|
||||||
|
{%- else -%}
|
||||||
|
{{- 'products.product.sold_out' | t -}}
|
||||||
|
{%- endif -%}
|
||||||
|
</span>
|
||||||
|
{% endunless %}
|
||||||
|
{%- elsif card_product_compare_at_price > card_product_price
|
||||||
|
and card_product.available
|
||||||
|
and show_sale_badge == false
|
||||||
|
-%}
|
||||||
|
{% if settings.dbtfy_discount_saved and section.settings.custom_badge_label == blank %}
|
||||||
{% render 'dbtfy-discount-saved',
|
{% render 'dbtfy-discount-saved',
|
||||||
product_compare_price: card_product_compare_at_price,
|
product_compare_price: card_product_compare_at_price,
|
||||||
product_price: card_product_price
|
product_price: card_product_price
|
||||||
@@ -878,7 +878,7 @@
|
|||||||
{%- endif -%}
|
{%- endif -%}
|
||||||
</span>
|
</span>
|
||||||
{% endunless %}
|
{% endunless %}
|
||||||
{%- elsif card_product.compare_at_price > card_product.price
|
{%- elsif card_product_compare_at_price > card_product_price
|
||||||
and card_product.available
|
and card_product.available
|
||||||
and show_sale_badge == false
|
and show_sale_badge == false
|
||||||
-%}
|
-%}
|
||||||
|
|||||||
Reference in New Issue
Block a user