Debut Theme - POA instead of €0.00

ChelseaColgan
New Member
2 0 0

Hi there,

 

I'm wondering is there a way to change some products from €0.00 to POA on the debut theme. It would only be select products, not all of them. Any advise would be appreciated! 

 

Thank you,

Chelsea 

0 Likes
suyash1
Shopify Partner
2872 307 476

@ChelseaColgan - means if product price is 0.00 it should display POA and not price? if yes then this needs code editng

You are welcome to contact me, my email - suyash.patankar@gmail.com
Free Shopify solutions/tutorials on youtube
#1 page builder app on Shopify - for FREE! PageFly
0 Likes
ChelseaColgan
New Member
2 0 0

Yes, it does need code editing. Any advise? 

0 Likes
cdevlin
Tourist
12 0 0

Hello,

I required this very feature on our company store and thought best to share with you how I did this. I don't use the Debut theme but I have downloaded it to test this out for you. 

In the themes page go to 'Edit Code' and search for the snippet called 'product-price.liquid'. 

Scroll down this code until you see the code section same as below that starts at line 51:

<div class="price__pricing-group">
    <div class="price__regular">
      <dt>
        <span class="visually-hidden visually-hidden--inline">{{ 'products.product.regular_price' | t }}</span>
      </dt>
      <dd>
        <span class="price-item price-item--regular" data-regular-price>
          {{ money_price }}
        </span>
      </dd>
    </div>
    <div class="price__sale">
      <dt>
        <span class="visually-hidden visually-hidden--inline">{{ 'products.product.sale_price' | t }}</span>
      </dt>
      <dd>
        <span class="price-item price-item--sale" data-sale-price>
          {{ money_price }}
        </span>
      </dd>
      <dt>
        <span class="visually-hidden visually-hidden--inline">{{ 'products.product.regular_price' | t }}</span>
      </dt>
      <dd>
        <s class="price-item price-item--regular" data-regular-price>
          {{ compare_at_price | money }}
        </s>
      </dd>
    </div>
    <div class="price__badges">
      <span class="price__badge price__badge--sale" aria-hidden="true">
        <span>{{ 'products.product.on_sale' | t }}</span>
      </span>
      <span class="price__badge price__badge--sold-out">
        <span>{{ 'products.product.sold_out' | t }}</span>
      </span>
    </div>
  </div>

delete this and replace with the following code:

{% if variant.price > 0 %}
  <div class="price__pricing-group">
    <div class="price__regular">
      <dt>
        <span class="visually-hidden visually-hidden--inline">{{ 'products.product.regular_price' | t }}hh</span>
      </dt>
      <dd>
        <span class="price-item price-item--regular" data-regular-price>
          {{ money_price }}
        </span>
      </dd>
    </div>
    <div class="price__sale">
      <dt>
        <span class="visually-hidden visually-hidden--inline">{{ 'products.product.sale_price' | t }}</span>
      </dt>
      <dd>
        <span class="price-item price-item--sale" data-sale-price>
          {{ money_price }}
        </span>
      </dd>
      <dt>
        <span class="visually-hidden visually-hidden--inline">{{ 'products.product.regular_price' | t }}</span>
      </dt>
      <dd>
        <s class="price-item price-item--regular" data-regular-price>
          {{ compare_at_price | money }}
        </s>
      </dd>
    </div>
    <div class="price__badges">
      <span class="price__badge price__badge--sale" aria-hidden="true">
        <span>{{ 'products.product.on_sale' | t }}</span>
      </span>
      <span class="price__badge price__badge--sold-out">
        <span>{{ 'products.product.sold_out' | t }}</span>
      </span>
    </div>
  </div>
  {% else %}
  <div class="price__regular">
      <dt>
        <span class="visually-hidden visually-hidden--inline">{{ 'products.product.regular_price' | t }}hh</span>
      </dt>
      <dd>
        <span class="price-item price-item--regular" data-regular-price>
          POA
        </span>
      </dd>
   </div>
  {% endif %}

Save the code and check your store to see if the change has worked.

Hope this helps.

0 Likes
Kreievo
New Member
1 0 0

Hi, Your code works but it still allows customers to proceed to checkout with the item at $0.00.

Can this be stopped?

0 Likes