Announcement

Collapse
No announcement yet.

Price Group message display on PROD page

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Price Group message display on PROD page

    Hello,

    I am trying to set a conditional on PROD page for customers that belong to a price group wholesale beginning with PA-.

    The conditional needs to show only the message for the people that donīt belong to those price groups and show nothing for the one that belongs.

    This is the code I'm posting on PROD page:

    On template PROD page: <mvt:item name="toolkit" param="pgroup|pcount" />

    On Product Display Layout:
    <mvt:if expr="g.acount GT 0">
    <mvt:foreach iterator="customer_pgroup" array="customer_pgroups">
    <mvt:if expr="l.settings:customer_pgroup:name EQ 'PA-117' OR l.settings:customer_pgroup:name EQ 'PA-119' OR l.settings:customer_pgroup:name EQ 'PA-121'
    OR l.settings:customer_pgroup:name EQ 'PA-123' OR l.settings:customer_pgroup:name EQ 'PA-125' OR l.settings:customer_pgroup:name EQ 'PA-127'
    OR l.settings:customer_pgroup:name EQ 'PA-129' OR l.settings:customer_pgroup:name EQ 'PA-130' OR l.settings:customer_pgroup:name EQ 'PA-131'
    OR l.settings:customer_pgroup:name EQ 'PA-132' OR l.settings:customer_pgroup:name EQ 'PA-133' OR l.settings:customer_pgroup:name EQ 'PA-134'
    OR l.settings:customer_pgroup:name EQ 'PA-135' OR l.settings:customer_pgroup:name EQ 'PA-136' OR l.settings:customer_pgroup:name EQ 'PA-137'
    OR l.settings:customer_pgroup:name EQ 'PA-138' OR l.settings:customer_pgroup:name EQ 'PA-139' OR l.settings:customer_pgroup:name EQ 'PA-140'
    OR l.settings:customer_pgroup:name EQ 'PA-141' OR l.settings:customer_pgroup:name EQ 'PA-142' OR l.settings:customer_pgroup:name EQ 'PA-143'
    OR l.settings:customer_pgroup:name EQ 'PA-145' OR l.settings:customer_pgroup:name EQ 'PA-147' OR l.settings:customer_pgroup:name EQ 'PA-149'
    OR l.settings:customer_pgroup:name EQ 'PA-151' OR l.settings:customer_pgroup:name EQ 'PA-153' OR l.settings:customer_pgroup:name EQ 'PA-155'
    OR l.settings:customer_pgroup:name EQ 'PA-157' OR l.settings:customer_pgroup:name EQ 'PA-159' OR l.settings:customer_pgroup:name EQ 'PA-161'
    OR l.settings:customer_pgroup:name EQ 'PA-163' OR l.settings:customer_pgroup:name EQ 'PA-165' OR l.settings:customer_pgroup:name EQ 'PA-167'
    OR l.settings:customer_pgroup:name EQ 'PA-169' OR l.settings:customer_pgroup:name EQ 'PA-175' OR l.settings:customer_pgroup:name EQ 'PA-179'
    OR l.settings:customer_pgroup:name EQ 'PA-183' OR l.settings:customer_pgroup:name EQ 'PA-191'">

    <mvt:if expr="g.shipping_message">
    <div class="free-shipping-note">
    </div>
    </mvt:if>
    <mvt:if expr="g.prodtext_note">
    <div class="free-shipping-note">
    </div>
    </mvt:if>
    <mvt:else>
    <mvt:if expr="g.shipping_message">
    <div class="free-shipping-note">
    <i class="fas fa-exclamation-circle"></i> <span> &mvt:global:shipping_message </span>
    </div>
    </mvt:if>
    <mvt:if expr="g.prodtext_note">
    <div class="free-shipping-note">
    <i class="far fa-dot-circle"></i><span>&mvt:global:prodtext_note;</span>
    </div>
    </mvt:if>
    </mvt:if>
    </mvt:foreach>
    <mvt:else>

    <mvt:if expr="g.shipping_message">
    <div class="free-shipping-note">
    <i class="fas fa-exclamation-circle"></i> <span> &mvt:global:shipping_message </span>
    </div>
    </mvt:if>
    <mvt:if expr="g.prodtext_note">
    <div class="free-shipping-note">
    <i class="far fa-dot-circle"></i><span>&mvt:global:prodtext_note;</span>
    </div>
    </mvt:if>

    </mvt:if>

    Thanks

    #2
    And maybe without toolkit?

    Comment

    Working...
    X