Page 1 of 1
[BUG] Coupons - applying to categories doesn't work [FIX!!!]
Posted: Thu Aug 23, 2012 12:14 am
by OC2PS
Not sure if it's just me, or if other have had this issue too.
When creating a coupon, I can choose the categories to which the coupon applies. However, seems the categories are not saved - when I click Edit for the coupon, all categories are unselected.
FIX:
i2Paq wrote:Coupons by Category
This vqmod changes the behavior of the category selector in the coupon code admin pages. Basically, it uses true categories for determining whether the code is valid or not, and not a static product list.
This will help users to not have to refresh the coupon code after adding new products.
Works like a charm!
Re: Coupons - applying to categories doesn't work
Posted: Tue Sep 04, 2012 9:25 am
by OC2PS
Any ideas?
Re: Coupons - applying to categories doesn't work
Posted: Thu Sep 13, 2012 5:23 am
by tmas73
Same problem here. Nothing saves! I am on Opencart 1.5.4.1
Re: Coupons - applying to categories doesn't work
Posted: Mon Sep 17, 2012 7:14 pm
by OC2PS
Bump
Re: Coupons - applying to categories doesn't work
Posted: Thu Dec 13, 2012 2:55 am
by qiux
Is it a bug or we are doing something wrong here? i also meet this problem, i doing search anywhere but got no luck and answer yet.
Here is the related topic.
http://forum.opencart.com/viewtopic.php?f=115&t=56862
Any idea?
Re: Coupons - applying to categories doesn't work
Posted: Mon Jan 28, 2013 7:06 pm
by toolsandtimber
Hi guys is there any update on this? We have just lost out on £120 because this failed to restrict our categories!!!
Re: Coupons - applying to categories doesn't work
Posted: Thu Jan 31, 2013 4:51 pm
by OC2PS
Does this work for anybody? Is it just a few of us that can't get this to work?
Re: Coupons - applying to categories doesn't work
Posted: Thu Jan 31, 2013 5:40 pm
by grgr
OC2PS wrote:Does this work for anybody? Is it just a few of us that can't get this to work?
What you are looking for won't work for anyone as the code and database table/fields don't exist for 'Categories' as that is not how it works.
When you tick a Category in the category list, all the products under that category should be added to the products list in the box below.
The system does not check for a category at checkout, it checks for a product. On the basis that the products belong to a category that you have allowed for the coupon, it's a seudo category check.
The advantage of this is that if there is a product or two in the category that you don't want to allow, then you can just delete the product from the resultant product list.
Re: Coupons - applying to categories doesn't work
Posted: Thu Jan 31, 2013 7:41 pm
by OC2PS
grgr wrote:When you tick a Category in the category list, all the products under that category should be added to the products list in the box below.
The system does not check for a category at checkout, it checks for a product. On the basis that the products belong to a category that you have allowed for the coupon, it's a pseudo category check.
And that would be fine, except it doesn't seem to work that way. Checking a category does not add its products to the products box - neither before nor after saving.
Re: Coupons - applying to categories doesn't work
Posted: Thu Jan 31, 2013 8:37 pm
by grgr
OC2PS wrote:Checking a category does not add its products to the products box - neither before nor after saving.
It should do, may take a few moments if there are a lot of products in the category.
Otherwise try the Console tab in Firebug to see what is happening.
Re: Coupons - applying to categories doesn't work
Posted: Wed Feb 13, 2013 1:51 pm
by cagbaazee
I m also facing same problem but it give me the display
Notice: Undefined index: left in /home/sssssssscx/public_html/eshoppy.org/opencart/catalog/model/checkout/coupon.php on line 60Notice: Undefined index: right in /home/ssssssscx/public_html/eshoppy.org/opencart/catalog/model/checkout/coupon.php on line 60Notice: Error: Unknown column 'c.left' in 'where clause'
Error No: 1054
SELECT COUNT(*) AS total FROM `oc_product_to_category` p2c LEFT JOIN `oc_category` c ON (p2c.category_id = c.category_id) WHERE p2c.`product_id` = '10245' AND c.`left` BETWEEN '0' AND '0' in /home/rapbaycx/public_html/eshoppy.org/opencart/system/database/mysql.php on line 50
do any one know how to resolve it
Thanks
Re: Coupons - applying to categories doesn't work
Posted: Thu Feb 14, 2013 12:48 am
by tolinho
Hi,
I also have this problem.
The coupon does not restrict for the selected categorys.
Its always appled.
Any advise?
Im running Open Cart 1541
Re: Coupons - applying to categories doesn't work
Posted: Fri Mar 29, 2013 6:41 pm
by i2Paq
Ran into this BUG today!
I'm having a major e-mail send out to 30.000 people this weekend, there is 5% discount for everyone who uses the discount code and now I find that it does not work for categories (nor does it add any product from the selected category).
How am I going to solve this?
Adding all my products manually?
This is undo-able as it also shows all the inactive product!!!
I'm using 1.5.4.1
Re: [BUG] Coupons - applying to categories doesn't work
Posted: Wed Apr 03, 2013 5:05 pm
by i2Paq
Coupons by Category
This vqmod changes the behavior of the category selector in the coupon code admin pages. Basically, it uses true categories for determining whether the code is valid or not, and not a static product list.
This will help users to not have to refresh the coupon code after adding new products.
Works like a charm!
Re: [BUG] Coupons - applying to categories doesn't work
Posted: Wed Apr 03, 2013 6:46 pm
by tolinho
i2Paq wrote:Coupons by Category
This vqmod changes the behavior of the category selector in the coupon code admin pages. Basically, it uses true categories for determining whether the code is valid or not, and not a static product list.
This will help users to not have to refresh the coupon code after adding new products.
Works like a charm!
Thanks for charing!
Ill give it a try

Re: [BUG] Coupons - applying to categories doesn't work [FIX
Posted: Sat Sep 14, 2013 7:05 am
by bruno05
Anyone fix this for 1.5.5.1? Cannot believe this is a bug and no one seems to have fixed it since 1.5.4.x.
Re: [BUG] Coupons - applying to categories doesn't work [FIX
Posted: Sun Sep 29, 2013 4:41 pm
by bruno05
Found a fix in the forums. Thanks you.
Re: [BUG] Coupons - applying to categories doesn't work [FIX
Posted: Wed Oct 02, 2013 8:48 am
by jackie
Hi - using 1.5.4.1, I have the same problem (coupons by category doesn't work - when it should be loading the category's products into the table, it does not load anything into the table...) The categories I've chosen are not saved.
We can set up coupons for specific products, and for the entire site, but need the category option to work.
How was this solved?
I understand from reading the posts that version 1.5.5.1 uses a different scheme for the coupons - could someone who uses this in 1.5.4.1 explain how you got it to work properly?
Thank you!!!
We also discovered this while trying to send out a newsletter with the coupons!
Re: [BUG] Coupons - applying to categories doesn't work [FIX
Posted: Wed Oct 02, 2013 2:21 pm
by i2Paq
jackie wrote:Hi - using 1.5.4.1,
How was this solved?
Did you actually read this topic?