X-Cart: shopping cart software

X-Cart forums (https://forum.x-cart.com/index.php)
-   X-Payments issues & questions (https://forum.x-cart.com/forumdisplay.php?f=50)
-   -   Cart Total doesn't match Order Amount (https://forum.x-cart.com/showthread.php?t=64413)

AMMoyer 07-27-2012 11:34 AM

Cart Total doesn't match Order Amount
 
I've added a drop ship charge to my XCart installation based on membership id. I've added some code to func.cart.php and func.order.php so that your order gets charged the appropriate drop ship fee based on your membership level. The cart shows the charge and the total is correct in XCart. It even gets written to the database field I addeed to xcart_orders table.

When you get to XPayments and enter your payment info, everything seems fine until it kicks you back to the store and the following error is shown.

Order processing error

Order declined.
Review your data or contact the store administrator.


Reason: Error: Transaction refused because of an invalid argument. See additional error messages for details. (The totals of the cart item amounts do not match order amounts.)
Go Back

I've checked the totals using the webmaster console and everything seems to be fine on the cart side, but somehow XP is checking the total charges against the cart totals and it's not matching so it bombs. Where is this check and how can I pass the drop ship charge to XP so the check is correct?

Thanks.

joss 08-06-2012 08:54 PM

Re: Cart Total doesn't match Order Amount
 
This error is not generated by X-Payments, but is returned the PayPal. Actually, it's self-explainable: please make sure that the $cart array is filled in correctly.

AMMoyer 08-07-2012 12:35 PM

Re: Cart Total doesn't match Order Amount
 
Thanks Joss, you are correct it is a PayPal error message. I was not able to make it work exactly how I wanted to, but have managed a work around. Basically, I added the dropship charges to the shipping charges in func.cart.php instead of having a separate charge. Then I backed the dropship charge out of $display_shipping_cost so that the last checkout page looked correct and it also shows the dropship charge so the customer sees all the correct information, but Paypal gets only the one shipping charge number with the dropship charges already added in.

gblair 08-14-2012 03:59 PM

Re: Cart Total doesn't match Order Amount
 
We had the same issue. If a customer used a coupon then we got the same error.

Qualiteam emailed me a patch which has resolved the issue. Might be worth contacting them and see if they can send it to you. I have an older version of x-cart so I'm reluctant to send you the file myself just in case it fails.

naemsmommy 08-27-2012 08:22 AM

Re: Cart Total doesn't match Order Amount
 
Quote:

Originally Posted by gblair
We had the same issue. If a customer used a coupon then we got the same error.

Qualiteam emailed me a patch which has resolved the issue. Might be worth contacting them and see if they can send it to you. I have an older version of x-cart so I'm reluctant to send you the file myself just in case it fails.


I saw your other post about this issue. Did QT end up refunding the charge? We are experiencing the same error.

gblair 08-27-2012 08:32 AM

Re: Cart Total doesn't match Order Amount
 
naemsmommy, X-Cart created a patch which we installed and it corrected the problem. No charge. I'm reluctant to post the patch in case it's version specific - I wouldn't want to muck up the works for you. I'd recommend contacting X-Cart for a patch.

I think this error falls into X-Payment's court since we did not receive the error if the customer was using the express checkout and we never received the error before Qualiteam installed X-Payments for us.

Good luck!


All times are GMT -8. The time now is 10:19 AM.

Powered by vBulletin Version 3.5.4
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.