I want to define a promotion rule(s) for specific users and specific product. Promotion rule is valid for specific period - it depends on the user.
For example
User A has a 50% discount for product X between 1 Mar 2024 - 8 Mar 2024
User B has a 50% discount for product X between 1 Apr 2024 - 8 Apr 2024
etc.
I was thinking about defining custom Marketing->Promotion rules for each user.
I'll set promotion start-end dates and set custom rule like that for Promotion Type: product:
<xsl:transform version="2.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
<xsl:template match="/">
<out>
<promotionPrice>
<xsl:if test="in/product/productVariant/productVariantID = 26 and /in/user/username = 'username_of_user_A'">
<xsl:value-of select="0.50 * in/product/productVariant/price" />
</xsl:if>
</promotionPrice>
</out>
</xsl:template>
</xsl:transform>
But it doesn't work. Price for logged in user is displayed without discount on Product List/Cart/Checkout.
Any ideas why?