This would be a handy condition when doing 3 for 2 or BOGOF offers.
At the moment, to do a 3 for 2 offer you have to do:
If ALL of these conditions are TRUE: If an item is FOUND in the cart with ANY of these conditions true: Quantity in cart is 3 Quantity in cart is 6 Quantity in cart is 9 << insert more if needed >>
Obviously this is a pain.
Ideally I could do this:
If ALL of these conditions are TRUE: If an item is FOUND in the cart with ANY of these conditions true: Quantity in cart is divisible by 3
This is a very interesting suggestion, as it is a shopping cart price rule that many Magento users will likely want to enable. Your suggestion of ‘is divisible by’ certainly is a shortcut for having to enter each number manually (3, 6, 9, etc.). However, this would not actually be the best condition to enter in order to create a “buy 3 get one free” rule. With either of the condition sets shown here, the rule will only account for orders containing exactly 3, 6, 9 etc. items. Most Magento users would probably not want to penalize the customer for purchasing 4 items, or 10 items, because you always want to encourage your customers to buy more products, but in this case they would receive no discount at all. This issue needs further attention, as this is such a common marketing tactic.
Assuming you want your rule to apply to all quantities, currently the best way to create a “buy 3 get one free” rule that applies to each factor of 3 would be to create a separate rule for each factor. The first rule would be for quantity greater than or equal to 3 and less than or equal to five, with a fixed amount discount equal to the price of one quantity of that product. The second rule would be for quantity between 6 and 8 with a fixed amount discount equal to the price of two quantities of that product, and so on.
I don’t understand the above rules.
About ‘is divisible by’ rule I’m agree because we sell wines bottles and packaging is for 6 bottles. For this quantity we optimize the packaging costs and we can make a discount to the customer.
@Moshe - Thanks! Glad to know are suggestions are being incorporated to make the product even greater.
@Garrone - Sounds like you want a discount if someone buys an exactly multiple of 6 bottles. Maybe a modulus rule is needed. E.g. If numbers of items in cart % 6 = 0, then give discount.
@Garrone - Sounds like you want a discount if someone buys an exactly multiple of 6 bottles. Maybe a modulus rule is needed. E.g. If numbers of items in cart % 6 = 0, then give discount.
I get an error, however it’s a very good possibility.
Fatal error: Call to a member function getFrontendInput() on a non-object in /home/tradizio/domains/tradizionidelsud.it/public_html/shop/app/code/core/Mage/CatalogRule/Model/Rule/Condition/Product.php on line 142
I get an error, however it’s a very good possibility.
Fatal error: Call to a member function getFrontendInput() on a non-object in /home/tradizio/domains/tradizionidelsud.it/public_html/shop/app/code/core/Mage/CatalogRule/Model/Rule/Condition/Product.php on line 142
I get this error also, any time I try to select one of the 3 “Cart Item Attributes”. It happens with any Checkout Price Rule I try to create in ver. 0.9.17740.
@Garrone: please replace with attached file: app/code/core/Mage/CatalogRule/Model/Rule/Condition/Product.php
Which attributes did you use in your price rule?
@seDev: you can’t be getting the same error when using Checkout Price rules, because the error above applies only to catalog price rules.
Could you please paste your error message?
Fatal error: Call to a member function getFrontendInput() on a non-object in /home/auth5t0/public_html/UK/app/code/core/Mage/CatalogRule/Model/Rule/Condition/Product.php on line 142
Fatal error: Call to a member function usesSource() on a non-object in /home/auth5t0/public_html/UK/app/code/core/Mage/CatalogRule/Model/Rule/Condition/Product.php on line 97