
Originally Posted by
rmjr
I have been using the quantity discounts v 1.11 on a 1.3.9d store for years. I am creating a 1.5.1 store and I can not get it working. I have installed it as per instructions and I copied my same file from the 1.3.9d installation (same store, just doing a refresh with a responsive template - celestial by Zen4me - checked and template doesn't matter for problem). I have updated the category with the new category number.
I only use it for a category discount and I changed the code in the modules/order_total/ot_quantity_discount.php file.
Here is my code that I customized:
function apply_special_category_discount($category, $count, &$disc_amount) {
switch($category) {
case 1:
if ($count >= 420) { $disc_amount = 5.2452381; } else
if ($count >= 210) { $disc_amount = 5.2523810; } else
if ($count >= 170) { $disc_amount = 4.7235294; } else
if ($count >= 130) { $disc_amount = 3.8692308; } else
if ($count >= 110) { $disc_amount = 3.6636364; } else
if ($count >= 90) { $disc_amount = 3.3666667; } else
if ($count >= 70) { $disc_amount = 2.90; } else
if ($count >= 50) { $disc_amount = 2.06; } else
if ($count >= 20) { $disc_amount = 2.05; } else
if ($count >= 10) { $disc_amount = 1.10; }
break;
Once again, this code is working great on a 1.3.9d store.
Any ideas?