Including Gift Vouchers in the Discount Coupon calculation
Currently, Zencart excludes Gift Voucher purchases from the Discount calculated at checkout. Regardless of whether the Coupon has no restrictions or whether the coupon is specifically set up to allow the GV product code in "restrictions" it is still excluded. To clarify, I would like to offer a $100 Gift Voucher for $90. The coupon would only be allowed once per customer. Also GV proceeds could not be used to then purchase an additional GV or someone could easily game the system. I have looked in the Order Total module and have not found any place where the GV is specifically excluded from the calculation. Can someone point me in the right direction?? PS - I am not a developer so please excuse any misuse of terms.
Re: Including Gift Vouchers in the Discount Coupon calculation
This posting by Ajeh (http://www.zen-cart.com/showthread.p...t-certificates) allows your store to offer discounted gift certificates. I'm not sure if that's exactly what you're looking for, but it's pretty close!
Re: Including Gift Vouchers in the Discount Coupon calculation
Quote:
Originally Posted by
lat9
Thank you so much LAT9 for the prompt response!! I've read that thread and it seems that the code cannot be used when the GV is priced are by attributes, which is how ours is priced, so maybe there is no way to do this?
Re: Including Gift Vouchers in the Discount Coupon calculation
You could customize the function is_product_valid and customize the section for:
Code:
if (preg_match('/^GIFT/', $product->fields['products_model'])) {
return false;
}
to allow the particular coupon_id to be validated regardless of the preg_match ...
I would customize this just for the specific coupon_id and not as a regular by pass of this safety ...
Re: Including Gift Vouchers in the Discount Coupon calculation
Quote:
Originally Posted by
Ajeh
You could customize the function is_product_valid and customize the section for:
Code:
if (preg_match('/^GIFT/', $product->fields['products_model'])) {
return false;
}
to allow the particular coupon_id to be validated regardless of the preg_match ...
I would customize this just for the specific coupon_id and not as a regular by pass of this safety ...
Thanks so much Linda! I will try that! Happy Holidays!