primadude Posted December 27, 2005 Share Posted December 27, 2005 I hope this question is not considered a cross post. I have a similar post in the CCVG thread but I have added more information here. This issue is relevent to both the most excellent CCVG contribution and this most excellent Credit Class and Gift Voucher "Easier to Understand" Payment Addon so I think it is acceptable to reword and repost here. :huh: I have a fully functioning CCVG v5.15 contribution. I recently installed the "Easy 2 Understand Payment Module v1.2" contribution. There is a problem when a voucher is available to a customer, the voucher total is more than the grand total, and the customer chooses NOT to use the voucher (tick notselected), selects a credit card payment, and continues checkout. The credit card module is then NOT used and the purchase is completed successfully without the customer paying for it. Example #1 (good): -This is a standard purchase. -No Gift Vouchers are available or used. -Authorize.Net Payment Module Used. -Note that the "Payment Information" section is displayed at Order Confirmation. -This is a good purchase. Example #2 (good): -This is a purchase using a $100 Gift Voucher Balance. -The grand total purchase is MORE than the $100 voucher. Therefore, additional payment is required to complete purchase. -The $100 voucher is used and applied to the total purchase. -Note that the "Payment Information" section is displayed at Order Confirmation. - This is a good purchase. Example #3 (bad): -This is a standard purchase. -A $100 gift voucher is available for use. -The grand total purchase is LESS than the $100 voucher. -The $100 gift voucher is NOT used for this purchase even though it is available. -Payment is required to complete purchase since the voucher is NOT used. -Note that the "Payment Information" section is NOT displayed at Order Confirmation. The order is confirmed and the payment is NOT processed through the payment module. -The sale is completed and the customer did not pay for the items! -This is a BAD purchase. The problem seems to be located in /catalog/checkout_confirmation.php at this code: $payment_modules->update_status(); // BEGIN >>> Contribution CCVG v5.15 $order_total_modules = new order_total; $order_total_modules->collect_posts(); $order_total_modules->pre_confirmation_check(); if ( (is_array($payment_modules->modules)) && (sizeof($payment_modules->modules) > 1) && (!is_object($$payment)) && (!$credit_covers) ) { tep_redirect(tep_href_link(FILENAME_CHECKOUT_PAYMENT, 'error_message=' . urlencode(ERROR_NO_PAYMENT_MODULE_SELECTED), 'SSL')); } // END <<< Contribution CCVG v5.15 if (is_array($payment_modules->modules)) { $payment_modules->pre_confirmation_check(); } When the tick box is not checked, even though the voucher can cover it, there needs to be a way to force a pre_confirmation_check. Currently, it seems to not be executing in the above scenario and I cannot find a way to tell PHP that the java script tick box is checked so I can edit the IF statement above to force the check. I am aware of a CCVG contribution called: Voucher_5.14_Final_Fix. However, I have experienced a bug implementing this fix, which is to comment out the above code in bold. Does this make any sense? Can someone tell me if this is happening to them also? I am pretty well stuck in the mud here. Thanks, Joe Quote Link to comment Share on other sites More sharing options...
primadude Posted December 28, 2005 Author Share Posted December 28, 2005 I hope this question is not considered a cross post. I have a similar post in the CCVG thread but I have added more information here. This issue is relevent to both the most excellent CCVG contribution and this most excellent Credit Class and Gift Voucher "Easier to Understand" Payment Addon so I think it is acceptable to reword and repost here. :huh: I have a fully functioning CCVG v5.15 contribution. I recently installed the "Easy 2 Understand Payment Module v1.2" contribution. There is a problem when a voucher is available to a customer, the voucher total is more than the grand total, and the customer chooses NOT to use the voucher (tick notselected), selects a credit card payment, and continues checkout. The credit card module is then NOT used and the purchase is completed successfully without the customer paying for it. ..... Thanks, Joe OK. I believe I have a fix in place. Please see this post: FIX Joe Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.