How to show only 1 specific variant price?

unitedflowers
Visitor
1 0 0

Hi. I'm using the Spotlight theme and I'm trying to make a price list for my flower shop. There are different prices for public customers and flower shops. We're already using the POS, so we have all our products set up with variants for Public and Florist prices. When I use product grids or related items, I would like the Public price to show. At the moment, I changed the underlined bit of code in the price.liquid file:

if target == product and product.price_varies
assign money_price = 'products.product.price.from_price_html' | t: price: money_price_max
endif

 

And it does show the highest price now, but we also have premium varieties of roses that are $25 for everyone. So instead of showing the public price of $20, it shows $25. So I'd like to know how to select specifically the prices named Public, like

 

if (price_variant == "public") {

money_price = price_variant;

}

Replies 0 (0)