Your cart is currently empty!
Reducing Affiliate Commission against Coupon
—
by
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%.
Posted in Affiliates Enterprise
Comments
3 responses to “Reducing Affiliate Commission against Coupon”
Thanks Eugen. It look pretty straight-forward to implement.
Hi David,
Thank you for the feedback. Glad I could help.
Do have an awesome day ahead.
Kindest regards,
Eugen.
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.