Reducing Affiliate Commission against Coupon

How can I reduce the commission rate by the amount of a coupon applied by the referred customer.

For example, Rate is 15%. Customer applied an affiliate related Woocommerce coupon for 10% during purchase. The result I am looking for is to reduce affiliate rate by 10%.

3 Responses to Reducing Affiliate Commission against Coupon

  1. David LeFevre October 14, 2020 at 1:33 am #

    Thanks Eugen. It look pretty straight-forward to implement.

    • Eugen Bleck October 14, 2020 at 12:39 pm #

      Hi David,

      Thank you for the feedback. Glad I could help.

      Do have an awesome day ahead.

      Kindest regards,
      Eugen.

  2. Eugen Bleck October 13, 2020 at 11:07 am #

    Hi David,

    I trust you are feeling awesome and well today!

    Thank you so much for using Affiliates Enterprise! It brings us great joy to know you are using our plugin.

    In order to achieve this you would have to:
    * Check the type of coupon used; if it’s that of an affiliate or not. This is to be done within the affiliates_formula_computer_variables filter
    * Apply a formula-based Rate. To which a general rule for your case would be: s – s*0.15. Where s represent the net transaction amount. You can read more on this HERE.

    In order to check if the coupon belongs to an affiliate use Affiliates_Attributes_WordPress::get_affiliate_for_coupon( ‘string-coupon-code’ ). This function would return the affiliate id on success or null

    Note:
    Please note that use of the API requires exhaustive PHP programming skills and the service of a qualified Software Engineer is recommended.

    STAY SAFE and I wish you a very fine and productive day ahead.
    Kindest regards,
    Eugen.

We use cookies to optimize your experience on our site and assume you're OK with that if you stay.
OK, hide this message.

Affiliates · Contact · Jobs · Terms & Conditions · Privacy Policy · Documentation · Downloads · Useful Plugins · My Account

Share