Shopify themes, liquid, logos, and UX
In Dawn, the sale badge appears if the item is in stock and the product price is less than the compare at price. If the item is out of stock the sold out badge appears if inventory is zero. This happens regardless of what price is entered into the compare at price.
We have gone into edit languages and changed the "Sale" text to "In-Stock". This works great until the product price is equal to the compare at price or if a compare at price isn't present. Knowing that the Sale badge has been edited to "In-Stock" is there a way to force the "In-Stock" text to appear regardless of the compare at price? Many products don't have a compare at price and it is not feasible to make one up.
Thanks!
Hi @jca123
This is indeed doable, would you mind sharing your store's URL so we can assist on that? It's a 1-min fix, however you would be losing the in-stock intelligence as you mentioned, so if you're okay with that let's do it!
Thanks for the reply. We are testing the Dawn template and it is not live.
I need the in-stock and sold out badges to work flawlessly based upon accurate inventory values.
I would like the in-stock (sale) badge to appear regardless of what the "compare at" price is set to. Currently, the in-stock badge disappears if the compare at price is equal to the price.
In the attached example, there are four products. The first three products are in-stock however the in-stock (sale) badge doesn't appear since product price and compare at price are equal or the compare at price is zero. The last product is out of stock and the sold out badge is present. The sold out product is priced similarly to the other three products in that the product price and compare at price are equal or the compare at price is zero. What code or lack of code allows the sold out badge to appear regardless of the compare at price?
Hi @jca123
You would have to remove the condition that compares the "compare at price" and the "price", can't really tell you where it is located without store access, however it's a quick conditional removal.
Hi @JHKCreate
We are still trying to accomplish this task now that we are on a 2.0 theme (District 4.0). How would we remove the " remove the condition that compares the "compare at price" and the "price" so the In-Stock badge would appear regardless of any price differences? Our website is www.andysmusic.com. A selection of products may be seen at the link below. Most products on this page do not have the instock badge because behind the scenes compare price and price are equal to one another.
Portrait of Stephen positioned next to an image of planet Earth, with the Stephen's World ...
By JasonH Mar 18, 2024Digital marketers and app developers have tracked activity in apps and websites for yea...
By Ollie Mar 13, 2024February was an exciting month with Shopify Editions, informative webinars, and more! F...
By JasonH Mar 7, 2024