Thanks...I was afraid that would be the answer. I think I can do a work around and change the zone rates to be determined by number of items purchased instead of total price....That isn't exactly what I want to do...but it should be close enough.
Printable View
Thanks...I was afraid that would be the answer. I think I can do a work around and change the zone rates to be determined by number of items purchased instead of total price....That isn't exactly what I want to do...but it should be close enough.
I'm new to zencart, have read the excellent guidance, installed quantity discounts and all seems to be working ok. However, I've also installed the promo material and would like to know how to change "Buy 3 or more of any item, get 10% off " to "Buy 3 or more items, get 10% off". I've searched all the mod files but can't find the text to change - can you help please?
Phil
Not sure what you mean by promo material, but you can try logging into your ZC admin and going to Admin>Tools>Developers Tool Kit and searching under "Look-up in all files" in "All Files - Catalogue and Admin". Search for the whole phrase verbatim, or part of it if you get no results. That should show you the file and line number of where you can edit the text.
If it is an order total module, it will most likely be /YOURWEBADDRESS.COM/includes/languages/YOURLANGUAGE/modules/order_total/THENAMEOFTHEMOD.PHP
Hope this helps.
The language on the promotional pages is still generated by Quantity Discounts, not the promotional pages themselves. The promotional pages just provide a container for the discount information. You'll want to look at
./includes/languages/english/modules/order_total/ot_quantity_discount.php
The trouble is, the statements themselves are sort of woven together word by word, so you might need to change the code file as well (i.e. ./includes/modules/order_total/ot_quantity_discount.php) to get the end result you want.
Good luck,
Scott
Thanks guys for your quick response. I went with Scott's direct approach, (him being the author and all) but as a newbie it's good to be reminded of stuff you just gloss over when you're trying to get your shop up and running - so thanks Fergus too. I amended the BASIS_CART definition in ./includes/languages/english/modules/order_total/ot_quantity_discount.php and all works like a dream.
We've been mainly using an asp cms to develop websites until now and so are new to zencart, but I have to say I think we've got to grips with the basics quite quickly and it's so powerful, especially with really useful add-ons like this one. We're here to stay!
On another note, I'm thinking of using zen for a restaurant in-house order placement application - can you please advise where's the best place to discuss requirements and design?
Thanks for all your help and hard work.
Best regards,
Phil
I've just installed the mod and everything works great, good mod.
Is there a way to have the Unit Price in the shopping cart reflect the quantity price instead of the original price?
If that could be done, would that means we can just hide the quantity discount line during checkout since the unit price would add up correct to the total then?
Thanks,
Well, after placing plans to integrate this mod with our website on the shelves, I'm dusting it off again.
So far, I've have the mod working beautifully right now in most aspects. The only problem I seem to be having is re-calculating tax. It appears that the discount is only re-calculating the tax on shipping (5% GST in Canada), and not the actual tax on the items (5% GST + 8% PST).
I know others have experienced the same issue, and I'm curious if there's a way to work around this? The problem is that the 8% PST may not always be charged; it all depends where it's being shipped too.
Does anyone have some ideas to get me started?
I have a client site with the Minimum Order add-on module installed. Client now wants to offer quantity discounts when total purchased is $250/$500/$1000.
Will this mod play nice with the minimum order mod?
Thanks,
Tina
FYI,
I installed this mod and haven't had any issues with the Minimum Order mod (although I set the minimum order value to -0-).
Great mod. Thanks!
Tina
hello
i didn't install the code yet but i have a question. what i want to do for my site is that for example: lets say somebody ordered $60worth of thing. they can choose a second item for $15 worth for free if they choose more then $15 for example $30 for the second item then i want it to reduce $15 off from $30 and charge the rest.
and i want some choices for example for a second choice if they order $100 then they can choose something worth $25.
is this module can do that or any other module ?
if it can i will try to install.
thank you in advance everybody for their hard work .:clap:
What you're asking for is not what this module does.
Hi, Swguy
Can your mod does following way of dicounting?
5% Discount on orders over £50
10% Discount on orders over £100
15% Discount on orders over £200
thanks!
Yes; discount by dollars spent was added in version 1.10.
Hi
thank you for the reply!
but this mod does not work if the website sells mix of both taxable and no-taxable products ? can you confirm it?
many thanks!
The restriction is you cannot recalculate tax (accurately) with a cart containing taxable and non-taxable items. You can use recalculate tax = no, and this is what many bricks & mortar retailers do.
Zen Cart does not break down the tax on an item by item basis, so it's impossible to reduce the tax on a mixed basket perfectly at the moment. Perhaps when the checkout rewrite is done, this issue will be addressed.
thank you for the explanation!
I am wondering what will happen if I use
zen cart's quantity discount on individual products + big dollar spending, on site sells mixed of taxable & non taxable items, and turn the "recaculate tax" off, what will happen? will result of reduction correctly inc tax?
many thanks!
I'm not absolutely positive what you're asking, but the logic that Big Spender uses to reduce tax is basically the same as the logic that Quantity Discounts uses. If you mix taxable and non-taxable items in the same basket and you're discounting with software I wrote, the only way you'll get a sensible number in all cases is to set recalculate tax to none and charge the full original amount of tax. In certain very specific cases for Quantity Discounts (but not Big Spender) you could write additional logic and get a close approximation in the manner that Group Pricing does; this is not something I support.
Like I said, when the checkout logic in Zen Cart is reworked so that taxes are available on a per item basis in the shopping cart object, I will update my code to provide more flexibility here, but until then this is a restriction.
thank you for reply!
It is pity your mod has such restriction under current version of zen cart, otherwise it will be extremely useful especially we are in recession now and shoppers like to see discount. let's hope future version of zen cart allows you to rewrite the mod.
once again, thank you very much for your help and time!
We have a variety of quantity discounts depending on the category. We have them set up and they work great but recently we had a customer that somehow went to a page that shows the default discount on the custom discounted category. They sent us a screenshot of the page and the interesting thing was that the cPath= in the url was for a category id that doesn't exist in our database.
So tested this an I can put any category id in the url and the product will still show up but the prolem is the discount text will display that category id's discount text or the default default.
So my problem is:
- why does a product show up if the catergory id doesn't match
- how can we ensure the customer sees the correct discount
Just to calrify when they go through the checkout process the correct discount is applied. We just have a problem of customer thinking we are giving them a raw deal becaue they see something different.
If you have custom category discounts, you can't just use the default marketing text; you need to write additional code.
Scott
I know that; I already have the custom text in the additional code. I am not having problems with the marketing text.
What I am taking about the fact that if the url to get to a product is /index.php?main_page=product_info&cPath=22&products_id=15
And category 22 has a custom discount of 25% and it shows the marketing text of 25%.
But if somehow a customer goes to the product as /index.php?main_page=product_info&cPath=60&products_id=15
when 60 is a non existing category the default marketing text shows instead of the customer marketing text that I have set. So the customer thinks they can get a higher percentage.
The reason I am asking is because a customer did this and thought he was going to get 50% off when the actual category should only get 25% off. The customer sent me screenshots and it showed a non existent catid in the url.
Sounds like $current_category_id may not be the master category id of the product in question; perhaps the product was linked at one time, perhaps the customer is just diddling the URL for fun. Who knows. In any event, if this is happening, you will need to query the category id manually instead of relying on $current_category_id. My Zen Cart Category Issues page discusses how to get this value.
http://www.thatsoftwareguy.com/zenca...issues.html#mt
The bulleted list of tips following the documentation on adding Marketing Text to Quantity Discounts
http://www.thatsoftwareguy.com/zenca...html#marketing
Has also been updated to discuss this issue and cross reference the resolution.
It's funny - this code has been in place for several years with no complaints, and in the last 2 weeks I've gotten two questions about this - the other was from Better Together.
I really want to try this mod. Trouble is I have no clue how to even install mods to zencart! :ohmy:
Anybody know where I should be looking to get help installing a mod like this one?
Thanks!
I wrote a very simple "introduction to installing my mods for rookies" page here:
http://www.thatsoftwareguy.com/zencart_install_mod.html
If this doesn't make sense to you, put an ad in Commercial Help Wanted to get someone who can walk you through doing this on the phone. It's only confusing the first time you do it.
Scott
Is there a way to have the discount figured immediately upon placing the quantity items in the cart? This is an awesome mod BTW!
Nevermind, I see the page for that, discount preview!
http://www.thatsoftwareguy.com/zenca...t_preview.html
I will have to add that someday!
I'm trying to set a discount for a specific product; I added the following code to the "apply_special_item_discount()" function:
case 397:
if ($count > 3 and $count < 6) {
$disc_amount = 6;
}
elseif($count > 6) {
$disc_amount = 12;
}
break;
But it's not working! Am I missing something, did I miss a step?
Remember that apply_special_item_discount can only be used with Discount Basis "Total By Item." I suspect you're using a different basis.
Here's a screenshot of my settings, let me know if you need to see anything else.
Where do I specify which categories to exclude from the discount? I just installed your most recent version.
I've looked in your info, but can't figure out where to do it.
Thanks!
I found where to do this in the php file, starting with line 190:
// Add categories you wish to exclude to exclude_category()
if ($this->exclude_category($products[$i]['category'])) {
continue;
and the category I want to exclude is #111, but I'm not sure where to put it in the above code.
Ok, I figured it out! I found your faq on how to do it, but was confused because I couldn't find the code used in your example:
function exclude_category($category) {
switch($category) {
But I searched again, and found it near the top, starting with about line 16.
So THANKS! I just tried it, and it worked with my changes.:clap:
I have a question. I am trying to setup quantity discounts for 12 units, 24 units, 36 units, and 48 units. I want the discount to ONLY affect those quantities, not the quantities in between. For example, 13 units gets no discount, 14 units gets no discount, etc. I tried setting 12 units and 10 as the percent off and then 13 units and 0 percent off, then 24 units as 10 percent off,etc. but it did not work. Any suggestions?
You have to write code to do this sort of thing. Use the apply_special_item_discount() user exit. It's described in the help on my home page.
Upon installing the Quantity Discounts mod together with the marketing promo in my 1.3.8a, I notice much to my annoyance that there are two lines of space between the "Store Quantity Discount Policy" heading and the discount schedule on all product pages with the promo, but not on the Quantity Discounts Promo page itself. What I wish is to have only one line, or rather 1em of space, between the heading and the schedule.
One of these lines (the topmost) is due to my forcing a margin-bottom: 1em; under all headings and paragraphs via the css, and I have no intention of removing this facility.
However, the other line of space completely eludes me, having played with many a margin and padding in the css's and even searched for excess <br /> in the program files.
As my site is not live, I am unable to provide a link.
Any help greatly appreciated.
[FONT="Verdana"]My taxes are getting all screwed up and as far as I can see everything is set up correctly. Can someone offer me some advice?
I am only charging sales tax to FL.
My shipping is a flat rate of $3.95
I have a discount set up so if they order 2 they get a 5% discount
In my quality discounts I have the Re-Calculate Tax set to standard.
Here is what I get when I do this for one item:
1 x Appalachian Pages 2009 Northbound 0% $15.95
--------------------------------------------------------------------------------
$3.95 Zone Rates (Shipping to US):
$0.00 Sales Tax:
$0.24 FL TAX 6.0%:
$20.14 Total:
Here is what I get when I order two items:
2 x Appalachian Pages 2009 Northbound 0% $31.90
--------------------------------------------------------------------------------
$3.95 Zone Rates (Shipping to US):
-$1.70 Quantity Discount:
$0.00 Sales Tax:
$0.14 FL TAX 6.0%:
$34.29 Total:
If you look at this you will see that the sales tax for FL is less when the total amount is higher. This is not right, the more the cost the more the sales tax should be.
I must be doing something wrong. Can someone offer some advice?[/FONT]
Thanks for such a quick response.
I have neither a class="content" nor id="discountPolicy3" in any of my css, although I do have a rem'd id="content" and I did create an id="discountPolicy1" in my stylesheet.css based on the styling in your Quantity Discounts Marketing Example 1 Code, which is what I am using.
In id="discountPolicy1", I have set both the margin and padding to 0, and there is nothing else therein that affects the layout. I suppose I could create a class="h2discountPolicy1" with margin-bottom set to zero.
I fear I may not have grasped the logic of <div class="x" id="y">, which I tend to treat as one or the other, but not a concatenation or subservience. Any heads up?
I cannot comment on any table styling until I am next at work.
I appreciate your help.
We just installed ZenCart and snatched up your module right away! We have discount tiers here based on order sub-totals... this thing rocks! Thanks so much for your contribution.
Further to above post (#350)
For the discounts table to appear on promo page as per css, you can edit includes\templates\lavender\templates\tpl_quantitydiscounts_promo_default.php (lines 25-42)
<br class="clearBoth" />
<?php
if (count($marketing_data) > 0) {
echo '<div class="content" id="discountPolicy1">' . "\n";
echo '<h4>' . STORE_POLICY . '</h4>';
echo '<ul>' . "\n";
for ($i=0, $n=count($marketing_data); $i<$n; $i++) {
echo '<li>'.$marketing_data[$i] . "</li>" . "\n";
}
echo '</ul>' . "\n";
echo '<br /></div>';
echo '<br class="clearBoth" />';
} else {
echo '<div class="content" id="discountPolicy1">' . "\n";
echo '<p>' . NO_QUANTITYDISCOUNTS_DISCOUNTS . '</p>';
echo '</div>' . "\n";
}
?>
It is a pity this kind of information/instruction is not easily located within ZC or with the addons, where it could save novices like myself countless hours of hapless searching and a good deal of frustration.
Thank you for the nice instructional documentation for this mod that comes with the installation, was a big help.
I am looking into using the Reward Points Module mod is there a way that I can set Quantity Discounts not to apply to order if they select to "cash in" the rewards points?
I was refering to this site: http://www.thatsoftwareguy.com/zenca...discounts.html sorry.... any way to block either mod so they cant be used together?
Like I said, there's nothing prepackaged to disallow quantity discounts on orders using rewards points. You could write custom software to do this, of course, but nothing exists at the moment to do this.
swguy, quick question... has there ever been a way to make quantity discounts disabled if a coupon is being used? thank you! this mod is excellent
Response by PM.
Hi -
I've installed the module and it works fine. Then I added the exclusions -- and most of my product page has disappeared along with the table for categories that were not excluded.
I'm perplexed. Here's the page, if that matters. I'm not sure what to do, I really need to add quantity discounts for one category, which contains multiple subcategories.
Help, please!
Ok, guess I pm'd you too soon. I had reinstalled zc because of issues with the cherry_zen template. So I reinstalled Quantity Discount on a stock osc template. The discount itself works fine, but when I exclude categories my right column gets wiped out.
I dunno, maybe I did something wrong. I did refer to your website & here is the code I used (just the part I changed, it's too long to post):
Now, I took out the exclusions & reuploaded and my right column came back. :wacko:Code:
<?php
/**
* Quantity Discounts in the order_total module
* Version 1.10
* By Scott Wilson (swguy)
* @copyright That Software Guy (www.thatsoftwareguy.com)
* @copyright Portions Copyright 2004-2006 Zen Cart Team
* @copyright Portions Copyright 2003 osCommerce
* @license http://www.zen-cart.com/license/2_0.txt GNU Public License V2.0
*/
class ot_quantity_discount {
var $title, $output;
var $explanation;
// Add categories you wish to exclude to this list.
// Go to Admin->Catalog->Categories/Products and look
// at the left hand side of the list to determine
// category id. Note that 99999 and 99998 are just given
// as examples.
function exclude_category($category) {
switch($category) {
case 14:
15:
16:
17:
18:
19:
20:
21:
22:
23:
24:
25:
26:
27:
28:
29:
30:
31:
32:
33:
return true;
}
return false;
}
There's a bug in your syntax. Instead of
you wantCode:switch($category) {
case 14:
15:
16:
17:
etc.
Code:switch($category) {
case 14:
case 15:
case 16:
case 17:
etc.
hi, i have quantity discount installed, but i met the problem when checkout
- i check out 2 items (price 20 + 30), total shipping cost 15.90, quantity discount 5%, tax 19.6%,
- i set the price with tax, and shipping cost no tax.
- i set the sort order which i want in module:
sub-total -- 200
shipping cost -- 210
quantity discount -- 220
taxes -- 230
total -- 240
----------------------------------------
which i should get is :
sub-total: 50.00
shipping cost: 15.90
quantity discount: -2.50
tax: 7.78
total: 63.40 [ total = 50+15.9-2.5 = 63.40 ]
----------------------------------------
But, no matter how i set up, its not what i want:
i set quantity discount: include tax - true, re-calculate tax - standard, i get
sub-total: 50.00
shipping cost: 15.90
quantity discount: -2.50 [ 2 items 41.81*0.05=2.09 (include tax = 2.50) ]
tax: 7.70
total: 62.91
----------------------------------------
i set quantity discount: include tax - true, re-calculate tax - none, i get
sub-total: 50.00
shipping cost: 15.90
quantity discount: -2.50 [ 2 items 41.81*0.05=2.09 (include tax = 2.50) ]
tax: 8.19
total: 63.40
----------------------------------------
i set quantity discount: include tax - false, re-calculate tax - none, i get
sub-total: 50.00
shipping cost: 15.90
quantity discount: -2.09 [ 2 items 41.81*0.05=2.09 ]
tax: 8.19
total: 63.81
----------------------------------------
i set quantity discount: include tax - false, re-calculate tax - standard, i get
sub-total: 50.00
shipping cost: 15.90
quantity discount: -2.09 [ 2 items 41.81*0.05=2.09 ]
tax: 7.78
total: 63.40
----------------------------------------
if i add more items, the amount would be more outrageous
when i turn off quantity discount, everything calculates correctly.
i'm using 1.38a
how do i fix the problem ? i like this module very much, i dont want to loos it. thanks
It seems the setting you wish is not available. You are welcome to modify the code or to hire someone to do it for you.
hello,
here's my invoice with quantity discounts on
sub-total: 50.00
shipping cost: 15.90
quantity discounts: -2.50
tax: 7.70
total: 62.91
the total calculation is not correct
total = sub total + shipping cost - quantity dissounts
= 50+15.9-2.5 =63.4
but i have no idea why 62.91
what i want is using quantity discounts, and calculation correct :unsure:
i do not have any special requirements, i just want the quantity discounts working on my zencart 1.38, but now the calculation is not correct :cry:
any help would be appreciated
hi swguy,
they are not the settings i wish but the settings i have tried, i have tried perhaps all settings cause the calculation is not correct in the invoice, i dont know which setting is correct, thats why i posted them here.
i do not have any special requirements, i just want the quantity discounts working on my zencart 1.38, but now the calculation is not correct.
here's my invoice when i turn quantity discounts on
sub-total: 50.00
shipping cost: 15.90
quantity discounts: -2.50
tax: 7.70
total: 62.91
according to the invoice, it should be :
total = sub total + shipping cost - quantity dissounts
= 50 + 15.9 - 2.5
= 63.4
but now the total is 62.91, its obviously wrong, but i have no idea how to fix this problem.
could you help me? thanks.
I Installed this mod and the preview feature in 1.3.8a. Works fine in every test I run. Today had a user checkout using paypal express checkout bypassing the checkout on my site. Discount was not applied. I assume this is because even though the preview can show the discount in the cart, it does not pass this discount to express checkout? Is there a way to apply the discount to users who choose the paypal express checkout method from the cart page?
I have not heard of this problem. Does it happen on every express checkout? Are you certain the user qualified for a discount with the items they had? Can you reproduce the problem?
Yes, he purchased 11 qty (we have discounts at 6 qty and 10 qty). I can't reproduce since I can't do a test paypal checkout. I can add the items to my cart and see the qty discount in the cart, but have no way to go to paypal and login to see the price (As soon as I try it says I can't pay myself:)). I just recently installed this and i have no other orders to compare to as far as express checkout.
I SHOULD mention that i have one page checkout mod installed. Not sure if that effects anything!
I will monitor and see if I have anything new to report. I'm glad to hear it SHOULD work with express checkout. I guess I just have to see if it is a fluke or is repeated. Thanks for this though, as an engraver, many people choose to add items one-at-a-time so they can put personalization on each item. Zen cart does not calculate qty discounts properly if added one-at-a-time like this mod does!
OK, I have to retract that!! In my testing I added items one at a time to see if this mod would calculate the discount even though I added one at a time. This worked because i never changed any attributes. After reading your reply I went back and added these items one at a time with different attributes each (merely changed the font selection) and low-and-behold it did NOT calculate a discount for the items.
I guess I'll have to message you private to see if you can do some custom coding for me. In fact, I'll go to your site and request it. Sorry for the confusion, I guess it is the attributes throwing it off.
Can somebody tell me how to temporarily disable this mod? Removing the file from my order_total folder gives me an error.
Is there another way?
I'm using Quantity Discount, thanks for the great mod :clap:
I have a question, for the following example, how to make the discount amount to the nearest figure... e.g. $6.80 or $6.90
Total Purchase = $68.10
Given 10% discount = $6.81
Total to Pay = $61.29
Thanks in advance :blush:
There's nothing built in; you'd have to write code.
Hi,
This mod allows you to set up to five quantity discounts on a per item, per category or total item basis.
Is there a way to set discount by Category ? :huh: how ? :blush:
Go to admin->modules->order total and select quantity discounts. Press Edit. Select Total Basis: Discount by Category. Press Update.
[FONT=Arial]We have been using Quantity Discount 1.8 with our Zen cart 1.38.[/FONT]
[FONT=Arial]We keep having a problem with orders that reach our discount levels, even the first discount level. [/FONT]
[FONT=Arial](We set it up so that for every 10 DVD's you buy you get one for free.)[/FONT]
[FONT=Arial]It seems we have everything set up right.[/FONT]
[FONT=Arial]What am I missing? [/FONT]
[FONT=Arial]This issue happens on both in Calif taxable orders, and out of state non taxable orders. It seems to be a cosistant $1.81 off some how.[/FONT]
[FONT=Arial]Here is the error code we get in linkpoint:[/FONT]
[FONT=Verdana]5499XXXXXXXX1750[/FONT]
[FONT=Verdana]Expires: 07/11[/FONT]
[FONT=Verdana]4581-71nKsg[/FONT]
[FONT=Verdana]SGS-002301: Charge total must be the sum of subtotal, tax, value added tax, and shipping.[/FONT]
[FONT=Verdana]result=LIVE; oid=4581-71nKsg; ip=75.1.5.153; ponumber=; subtotal=241.45; tax=20.33; shipping=5; chargetotal=244.83; cardnumber=5499XXXXXXXX1750; cardexpmonth=07; cardexpyear=11; cvmindicator=provided; cvmvalue=724; userid=1; customerid=1; name=Kathleen Fielder; company=; address1=6850 Canby Ave. #106; address2=; city=Reseda; state=California; country=US; phone=818-881-5901; email=webmaster AT girlfriendsfilms DOT com; addrnum=6850 Canby Ave. #106; zip=91335; sname=Jim Koshak; saddress1=6850 Canby Ave. #106; saddress2=; scity=Reseda; sstate=California; szip=91335; scountry=US; comments=Website Order; items=Array ( [0] => Array ( [id] => 145 [description] => ############## Seductions 25 [quantity] => 10 [price] => 21.95 ) [1] => Array ( [id] => 146 [description] => ############## Triangles 14 [quantity] => 1 [price] => 21.95 ) ) ; ordertype=[/FONT][FONT=Verdana]SALE[/FONT][FONT=Verdana];[/FONT]
[FONT=Arial]We need to get this straightened out asap![/FONT]
[FONT=Arial]Any help would be appreciated.[/FONT]
[FONT=Arial]My config of the module is:[/FONT]
[FONT=Verdana]Quantity Discount[/FONT]
[FONT=Verdana]© That Software Guy[/FONT]
[FONT=Verdana][FONT=Calibri]Donate[/FONT] - Support this Module[/FONT]
[FONT=Verdana][FONT=Calibri]Help[/FONT] - View the Documentation[/FONT]
[FONT=Verdana]This module is installed[/FONT]
[FONT=Verdana]true[/FONT]
[FONT=Verdana]Sort Order[/FONT]
[FONT=Verdana]295[/FONT]
[FONT=Verdana]Include Tax[/FONT]
[FONT=Verdana]false[/FONT]
[FONT=Verdana]Re-calculate Tax[/FONT]
[FONT=Verdana]Standard[/FONT]
[FONT=Verdana]Discount Units[/FONT]
[FONT=Verdana]currency[/FONT]
[FONT=Verdana]Discount Basis[/FONT]
[FONT=Verdana]Total Items in Cart[/FONT]
[FONT=Verdana]Discount Level 1[/FONT]
[FONT=Verdana]10[/FONT]
[FONT=Verdana]Discount Amount 1[/FONT]
[FONT=Verdana]21.95[/FONT]
[FONT=Verdana]Discount Level 2[/FONT]
[FONT=Verdana]20[/FONT]
[FONT=Verdana]Discount Amount 2[/FONT]
[FONT=Verdana]43.90[/FONT]
[FONT=Verdana]Discount Level 3[/FONT]
[FONT=Verdana]30[/FONT]
[FONT=Verdana]Discount Amount 3[/FONT]
[FONT=Verdana]65.85[/FONT]
[FONT=Verdana]Discount Level 4[/FONT]
[FONT=Verdana]40[/FONT]
[FONT=Verdana]Discount Amount 4[/FONT]
[FONT=Verdana]87.80[/FONT]
[FONT=Verdana]Discount Level 5[/FONT]
[FONT=Verdana]50[/FONT]
[FONT=Verdana]Discount Amount 5[/FONT]
[FONT=Verdana]109.75[/FONT]
[FONT=Calibri]Thanks in advance,[/FONT]
[FONT=Calibri]Jim[/FONT]
[FONT=Futura Hv]Jim Koshak[/FONT]
[FONT=Futura Hv]Website Engineer[/FONT]
[FONT=Futura Hv]Director Internet Services.[/FONT]
[FONT=Futura Hv]Girlfriends Films Inc.[/FONT]
Some changes have been made to the LinkPoint payment module; do you have those installed on your cart? Search the forum for LinkPoint to find them.
here is my current linkpoint settings
Linkpoint/YourPay Merchant Login
Troubleshooting/Setup FAQ
Enable Linkpoint Module
True
Linkpoint/YourPay Merchant ID
829**
LinkPoint Transaction Mode Response
LIVE: Production
Authorization Type
Immediate Charge/Capture
Set Order Status
Processing [2]
PREAUTH Order Status
Pending [1]
Refund/Void Order Status
Pending [1]
Sort order of display.
0
Payment Zone (restrict to)
--none--
Fraud Alerts
Yes
Enable Database Storage
True
Debug Mode
Failure Alerts Only
See this thread for the fix.
http://www.zen-cart.com/forum/showpo...7&postcount=19
Thanks that worked!!
http://www.zen-cart.com/forum/showpo...&postcount=382
##############################___
Hello:
I have hit a wall with my website. I have installed the quantity discount addon and it works perfectly. The user exits are a great feature. My problem is I need to be able to use the user exits for only a select group of members. Is it possible to merge both group pricing and quantity discounts so that only people in group a get the quantity discount. I have seen this asked before but never an answer to the problem. I know there is going to have to be some programming here but do not know where to start. Any help is much appreciated.
Josh
Quantity Discount Levels For Separate Categories:
SWGuy: I have seen this question posted 4 times in this thread, (and it is a long one) with no real answer.
ZC version 1.3.8 - your Quantity Discounts module 1.10 installed and working.
The Admin/Order Totals/Quantity Discounts is installed, no tax or tax calculations, discount units by percentage, Discount basis by category, counting method = Items.
There are no standard Zen Cart discount structures applied in the whole shop. The only other mods are Purchase Order (a payment mod encountered only after Order Totals) and Columns.
The discount structure applied in the Admin/Order Totals/Quantity Discounts module is: 5 to 10 items=5% discount, 10+ is 10%. The rest are blank. This works OK, and discounts are excluded on the "Excluded Categories" in the modules/order_totals/ot_quantity_discount file.
The basic problem is that the user exit for categories with separate discount policies will NOT override the default discount listed in the Admin section.
Here is the code from that section of ot_quantity_discount.php
// Add categories with special discounting policies to this list.
// Note that 99999, 99998 and 99997 are just given as examples.
// Note that the Discounting Units you specified in Admin
// (percentage, currency, currency/item) are also used here.
function apply_special_category_discount($category, $count, &$disc_amount) {
switch($category) {
case 29:
if ($count > 10) {
$disc_amount = 5;
}
break;
case 99997:
$disc_amount = 75;
break;
}
}
Here's the deal: If I order 9 of the units in Category 29, I should get no discount. But I get the standard 5% as entered in Admin. I will eventually expand this to have different discount rates on about 5 other categories, and order and install most of your commercial mods, but I have to get this working first.
Yes, this the correct parent category for the products listed under it. I am also required to make the discount for the same category go to 10% if 25 items are purchased. I tried it various ways, but syntax errors on my end crashed the page when trying to add the next level into this code section. Let's keep it simple and get a single one working first........
Any advice would be appreciated.
You have not coded the behavior you want explicitly. Instead of:
it sounds like you wantCode:case 29:
if ($count > 10) {
$disc_amount = 5;
}
Code:case 29:
if ($count <= 10) {
$disc_amount = 0;
} else if ($count > 10) {
$disc_amount = 5;
}
Thanks for the fast response. I am trapped over the weekend in Toronto in a hotel with nothing to do, but you should take more time off.......
That part almost works. I tried the "else if" statements before bugging you, but had the brackets in the wrong place. (I guess that's why you make those big bucks....) I am an HTML wizard, but PHP isn't as forgiving.
Anyway, that works, except for when I enter 10 items exactly. 9 items shows no discounts at all, and 11 gives me 5%, but 10 exactly gives me the default 10% in the Admin setup.
function apply_special_category_discount($category, $count, &$disc_amount) {
switch($category) {
case 29:
case 30:
if ($count <= 9) {
$disc_amount = 0;
} else if ($count > 10) {
$disc_amount = 5;
}
I need to also have the ability to change the discount to 10% if the items exceed 25. I have searched high and low on your pages and the forums while attempting to make it happen, and crashed the PHP repeatedly in my attempts.
You get enough of the whiners wanting freebies, but lastly, the override of the category discount in this page does not seem to add up the totals between the two (or more) listed categories to determine the discount level. The default settings in the Admin section of your mod work perfectly in the categories that don't need the override........
Is this a syntax error on my part, or is this something you could do for me on a commercial basis?
Thanks again, and try to get out more.......:smile:
Response by PM.
Hi,
I've noticed an error in the amount of tax displayed in the transaction as follows:
I am in the UK with tax rate of 15% applied to goods and shipping. For the purposes of this example i am using a product at £10 with a discount rate of 10% and free shipping.
The checkout totals should be:
Sub-Total: £100.00
Free shipping (Free shipping): £0.00
Quantity Discount: -£10.00
Included VAT @ 15%: £11.74
Total: £90.00
However, they are displaying as follows:
With Include Tax: True, Recalculate tax: None:
Sub-Total: £100.00
Free shipping (Free shipping): £0.00
Quantity Discount: -£10.00
Included VAT @ 15%: £13.04 (the tax on £100 - incorrect)
Total: £90.00
With Include Tax: False, Recalculate tax: None:
Sub-Total: £100.00
Free shipping (Free shipping): £0.00
Quantity Discount: -£8.70
Included VAT @ 15%: £13.04 (the tax on £100 - incorrect)
Total: £91.30
With Include Tax: True, Recalculate tax: Standard:
Sub-Total: £100.00
Free shipping (Free shipping): £0.00
Quantity Discount: -£10.00
Included VAT @ 15%: £11.54 (the tax on £88.50 - correct)
Total: £88.50
With Include Tax: False, Recalculate tax: Standard:
Sub-Total: £100.00
Free shipping (Free shipping): £0.00
Quantity Discount: -£8.70
Included VAT @ 15%: £11.73 (the tax on £89.99 - correct)
Total: £89.99
Therefore, none of the combinations allow the checkout totals to display correctly. The discount should include the tax and the tax should be calculated based on 15% of the total, not 15% of the subtotal.
Any help on this issue would be much appreciated.
It appears to me that this is a ZC issue rather than a module issue. Bug report posted here:
http://www.zen-cart.com/forum/showthread.php?p=713637
I just successfully loaded this mod and all is working, except I still see "Sorry, there are currently no Quantity Discounts" after editing the promo page in the define_pages editor. I do have a discount setup, using your mod, based on % of the total purchase. Am I missing something?
Thanks for a great mod and I'll make a donation.
Jack
Zen Cart v. 1.3.8
Hmmm...
./includes/modules/pages/quantitydiscounts_promo/header_php.php
has not been installed? Perhaps Quantity Discounts isn't installed under Admin->Modules->Order Total?
Those are installed.
The discount is computed on the Step 2 of 3 page, but I am referring to the promo page with the link on the sidebox. The page that is editable from the define_pages editor, where the discount is explained. I temporarily took it out of the php file for now, but activating the mod doesn't automatically do so.
Hi swguy,
I've been having some problems with the way that ZC is calculating the tax percentage on orders. It appears to have been cleared up for the discount coupon module, but not for the Quantity Discount one.
When:
Include Tax
true
Re-calculate Tax
None
Sub-Total: £100.00
Free Shipping: £0.00
Quantity Discount (10%) :-£10.00
Included VAT @ 15%:£13.04 (incorrect)
Total:£90.00
When:
Include Tax
false
Re-calculate Tax
Standard
Sub-Total: £100.00
Free Shipping: £0.00
Quantity Discount (10%) :-£8.70
Included VAT @ 15%:£11.73
Total:£89.99
Any help on this would be much appreciated.
Please help?
I moved the category I used QD for up to top level, and then the mod stopped working altogether.
I tried moving the category back, and I've tried making a new category - nothing works. :no:
What to do?
http://www.hjemmemamma.com/nettbutikk
Never mind, it just magically started working again, I've no idea why... :)
The discount promo page just shows the settings you have for QD in admin. If you've done special things in ot_quantity_discount.php, you need to edit the define page for the promo page and add some text.
I can't reverse engineer your mods and describe them for your customers. :)
That kind of makes sense. I just wanted to be sure the mod was working properly.
Just a note: the following documentation is incorrect when it states:
Please forgive me if I'm not understanding something.Code:Q: I only want discounts applied to items in category 11. How do I do this?
A: Update the function exclude_category() in includes/modules/order_total/ot_quantity_discount.php as follows:
function exclude_category($category) {
switch($category) {
case 11:
return false;
}
return true;
}
Q: I don't want discounts applied to items in category 7. How do I do this?
A: Update the function exclude_category() in includes/modules/order_total/ot_quantity_discount.php as follows:
function exclude_category($category) {
switch($category) {
case 7:
return true;
}
return false;
}
The documentation is not incorrect. This is how it works. If it's not working for you, you have one of the category issues which I documented on this page.
http://www.thatsoftwareguy.com/zenca...ry_issues.html