Coupons that have a NULL value for the cpnStartDate field are not properly handled. On upgrade, are you updating that date to '2000-01-01 00:00:00'? We may be adding coupons without start dates and the cart is not calculating the coupon value if the cpnStartDate is NULL.
Dean ecomwebstore.com [img]http://www.ecomwebstore.com/images/ecw_sm.jpg[/img]
quote:On upgrade, are you updating that date to '2000-01-01 00:00:00'?
Hi Dean Yes, the cpnStartDate is set to that value when updating. Are you having a problem? There is a fix in the incdiscounts.php file where the End Date could be incorrectly marked as Expired in case that has anything to do with this.
Hi Dean I've added a check for NULL also as it should be handled properly really anyway. I've added that change to the v7.1 updater incdiscounts.php file. You can use that with v7.0 if you are still on that version.
My understanding is that on updating NULL will be changed to 2000-01-01 00:00:00 which effectively means there is no start date as such as it's in the past.
quote:So does that mean that if cpnStartDate is NULL it will be treated as a "None" start date?
Actually, I don't think I've thought this through properly. What I did was handle the NULL in the admin, but in the cart a NULL would still not be handled properly. Can you maybe run a quick bit of SQL to set all start dates and end dates if they are NULL? On update and through the admin when adding discounts they should always be set with the default "not set" value.