Targeting 'Catalogue Discount' with Liquid markup


is there way target user's 'catalogue discount' (who not wholesaler) similar method target wholesalers? eg. {% if this.globals.user.isloggedin , globals.user.iswholesaler == true , {{retailprice}} > {{saleprice}} %} or similar(?) - along lines of 'globals.user.hasdiscount'

yes.

 

without tax it's {{ saleprice }} vs {{ discountprice }}

with tax it's {{ totalprice }} vs {{ totaldiscountprice }}

 

so, in code translates to:

{% if globals.user.iswholesaler == true , saleprice > discountprice -%}
<p>logged in wholesaler has discount</p>

{% endif -%}

note: applies visitor has applied discount code @ checkout; , browsing store.



More discussions in Developer forum


adobe

Comments

Popular posts from this blog

Reader DC

AdobeIDの作り方

Adobe InDesign CC 2017 has stopped working