- Posts: 18
- Thank you received: 0
Multiple Quantity Discounts
For every widget sold, no matter what variant I need to have a cost for qty 1-3, qty 4-7, and qty 8+
I bought the essential to get this working with coupons, and have two coupons set up - one that is to kick in at 4 or more, another at 8 or more. But of course, only the first gets autoloaded no matter the quantity. I know that I could have the customer delete the one and enter the other at checkout, but the client really wants this automated.
What I really need is quantity pricing by category. Any ideas?
Aubrey
Please Log in or Create an account to join the conversation.
If you use the latest version of HikaShop, the auto loaded coupons now reload automatically when the cart changes so the customer don't have to delete anymore the coupon to get the new coupon price based on his new cart.
Please Log in or Create an account to join the conversation.
...I know that I could have the customer delete the one and enter the other at checkout...
Oops. I take that back. It does show the coupon deleted, but it is still there. I guess it is automatically adding it back.
Please Log in or Create an account to join the conversation.
The problem is, we did a custom add to cart via ajax link. Basically we are running an array to submit add to cart urls. Is that causing the problem?
Please Log in or Create an account to join the conversation.
As I said, that won't work with previous versions of HikaShop. Are you using the latest version 1.5.2 ?
Please Log in or Create an account to join the conversation.
Please Log in or Create an account to join the conversation.
Please Log in or Create an account to join the conversation.
[url] screencast.com/t/cXUS2dl2Ez [/url]
[url] screencast.com/t/eqDDlKx4PQz [/url]
Please Log in or Create an account to join the conversation.
Please Log in or Create an account to join the conversation.
Please Log in or Create an account to join the conversation.
the coupon change is done when the items quantity is n+1 instead of n in the cart. Do you confirm ?
Please Log in or Create an account to join the conversation.
Please Log in or Create an account to join the conversation.
Please Log in or Create an account to join the conversation.
Please Log in or Create an account to join the conversation.
Please Log in or Create an account to join the conversation.
I had to change the code:
$query = 'SELECT * FROM '.hikashop_table('discount').' WHERE '.implode(' AND ',$filters).' ORDER BY discount_minimum_order DESC';
to:
$query = 'SELECT * FROM '.hikashop_table('discount').' WHERE '.implode(' AND ',$filters).' ORDER BY discount_minimum_order DESC, discount_minimum_products DESC';
in the file administrator/components/com_hikashop/classes/cart.php
and that fixed the problem. We'll include it in next version.
Please Log in or Create an account to join the conversation.
Having one slight issue though. The client wants a round number discount -- example, 1-3 price = 149, 3-7=129, 8+ = 99. To get the percentage discount to even numbers requires more than 2 decimal positions for the calculation, but it seems only two are used to calculate.
If changing that is a big deal, is there a limit on the number of coupons that can be active? A workaround would be to have a coupon for a certain amount off for qty 3,4,5,6,7,8,9,10... etc
Thanks again for all your help!
Please Log in or Create an account to join the conversation.
Please Log in or Create an account to join the conversation.
Please Log in or Create an account to join the conversation.