Page 1 of 1

Order Coupon Showing up Inconsistently

Posted: Wed Apr 07, 2010 4:41 pm
by Diavan
I'm trying to add a very simple 10% coupon (type Order) to the orders.

When applied to a cart the Coupon with fewer items it might show up as one line item (which is rare).
However as the basket items increase gradually the number of coupon line items increase randomly.
The Coupon total comes up correct though.

The way it show up multiple time is confusing as well. Hard to figure out how many products one coupon is attached to.
If it is a Order Coupon it 'should' show up once as a basket item. Or am I assuming it wrong??
Is there a way to workaround this. Am I missing any settings??
I tried many different settings with Allow Combine, Min purchase, Max Value didn't seem to work.

Appreciate any help. Thanks.

Image

Image

Image

Image

Re: Order Coupon Showing up Inconsistently

Posted: Wed Apr 07, 2010 8:36 pm
by igavemybest
How many warehousese are the products set to ship from?

Re: Order Coupon Showing up Inconsistently

Posted: Thu Apr 08, 2010 7:47 am
by mazhar
I guess in current implementations one order coupon is created per shipment. It seems like most of your products are having different shipment in basket that's why its showing different coupon per shipment.

Re: Order Coupon Showing up Inconsistently

Posted: Thu Apr 08, 2010 8:43 am
by Diavan
I understand that the coupons are connected to shipments which is what we needed - so for three shipments the order coupons should show up as many times. But that's not the case here.

My concern was that why:
- Coupon shows up 2 times for first shipment (12 items)
- Coupon shows up 2 times for 2nd shipment (2 items)
- Coupon shows up 1 time for 3rd shipment (3 items)

I'm trying to figure out the line item logic behind the order coupons.
Why are these coupons breaking up in the first place.
They should have been appearing One time for each shipment regardless of items in that shipment. No??

Re: Order Coupon Showing up Inconsistently

Posted: Thu Apr 08, 2010 2:16 pm
by jmestep
When you set up the order coupon, do you allow all products, or just some? Maybe it splits it if you only allow some products. I tested an order coupon with allow all products and it didn't split things up.

Re: Order Coupon Showing up Inconsistently

Posted: Thu Apr 08, 2010 6:06 pm
by Diavan
I have it selected as "Valid for any Product" as shown in the first snapshot.

Re: Order Coupon Showing up Inconsistently

Posted: Fri Apr 09, 2010 7:16 am
by mazhar
BTW how many warehouses are there and how many products in basket have different warehouses. System creates different shipments for different warehouses.

Re: Order Coupon Showing up Inconsistently

Posted: Fri Apr 09, 2010 7:50 am
by jmestep
Maybe it happens when there is a volume discount item in the basket also?

Re: Order Coupon Showing up Inconsistently

Posted: Fri Apr 09, 2010 7:40 pm
by Diavan
mazhar wrote:BTW how many warehouses are there and how many products in basket have different warehouses. System creates different shipments for different warehouses.
I just removed any item that is shipped from a separate warehouse. The basket only contains items shipped from one location now.
jmestep wrote:Maybe it happens when there is a volume discount item in the basket also?
Deleted the Discount from the system as well. I deleted any other coupons added to the basket.

Image

When I start removing items one by one in the basket.aspx page at some point the two line items for coupons convert into one.
I just can't figure out why !!

Re: Order Coupon Showing up Inconsistently

Posted: Sat Apr 10, 2010 7:00 am
by jmestep
I have been working on custom coupon code off and on and I have thought that at times I had seen the coupons grouped into one item in the basket and at other times seen it split out. I haven't tried to trouble shoot it and until you brought it up, I thought maybe I was remembering things incorrectly and couldn't replicate the issue when I tried. Able is working on a coupon bug, so maybe this recalculation is related to that also.
Here is the bug:
http://bugs.ablecommerce.com/show_bug.cgi?id=8849

Re: Order Coupon Showing up Inconsistently

Posted: Sat Apr 10, 2010 12:26 pm
by Diavan
Hope to see a patch soon then.
Its not a show stopper - just a little confusing for the users.
Thanks Judy.

Re: Order Coupon Showing up Inconsistently

Posted: Tue Nov 02, 2010 2:25 pm
by AussieInSeattle
I just ran into this issue ($25 off any order as an order coupon) and I fixed in teh following way:
In Basket.ascx.cs around line 79 (AC7.0.5) in the GetBasketItems method I added this to the existing if/else statement:

code removed due to issues in testing

Re: Order Coupon Showing up Inconsistently

Posted: Tue Nov 02, 2010 3:06 pm
by AussieInSeattle
Had to make a similar edit so that the emails that are sent out aren't split like you see in the UI.
Changes made to OrderItemCollection.cs (you'll need source code for this change).
All of these changes rely on you having coupons uniquely named - its all somewhat of a hack for what I see as a bug.

Code: Select all

removed code as it caused other issues

Re: Order Coupon Showing up Inconsistently

Posted: Tue Nov 02, 2010 3:22 pm
by AussieInSeattle
I should also mention that all the above code is untested at this point - I'll post back with any fixes if I run into issues.