Show discounted price on product page Dawn theme

Hi, currently in the process of switching to the Dawn theme and would like to display the discounted price on the product page and collection page (see attached). I am not talking about the “compare at price”, but would like to display an automatic discount.

I achieved this with this code in liquid:


              ~~{{ current_variant.price | money }}~~
               **{{ product.price | times: 0.80  | money }}**
            

the code above displays 20% discount and I have 20% automatic discount code applied in cart and checkout.

How can I do this with json?

1 Like

hi @User1233 ,

i’m unclear the thing you want, can you please explain more about that? If possible can you please give the link to your store?

Thank you!

1 Like

@User1233

Please check following link for help

https://liquify.design/shopify-developer-guide-display-percentage-discount-shopify/

if any problem let me know!

Thanks!

1 Like

https://diamondshoaljewelers.com/collections/luminox/products/tide-recycled-ocean-material-eco-series-watch-0321

We have an automatic 20% discount for watches, so customer does not need to enter a discount code at the checkout, it’s automatically applied at the checkout.

In order for the customer to see the discounted price on the product page, I edited product-template.liquid (see the code in the original post). Now, I am transitioning to the new Dawn theme and the product template is in json and not liquid, so I am asking ow to do the same thing in json.

How do I display already discounted price on the product page?
The product price needs to reflect the automatic discount that is applied at the checkout.

3 Likes

This is not the same!
I am not talking about “compare at price”.

We have an automatic discount that is applied at the checkout, so customer does not need to enter any coupon codes.

I want to display discounted price on the product page, just like I did it in liquid (see code in original post), but I don’t know how to do it in the new Dawn theme with json.

4 Likes

Which liquid file did you edit to get the strike through?

I would like to know as well. I think this should be a standard feature as customers would like to know before they get to the checkout

3 Likes

Have you solved? I have the same problem

I ended up going off of this response, but it only shows the discounted price on the main pages and in collections, not the actual individual item. Since it changes the code, I duplicated the theme and named it “sale” for this purpose. Just remember to change it back after the sale. Also, next time there’s a sale any updates made to the main theme won’t transfer.

https://community.shopify.com/c/shopify-design/original-price-crossed-out-next-to-discounted-price-in-red/m-p/1680058#M448778