Page 1 of 1
CheckoutResponse.Success 'True' even with failed Transaction
Posted: Mon Mar 29, 2010 4:05 pm
by Diavan
I've been getting the CheckoutResponse object Success flag 'true' even if the Gateway Transaction status is '0' (TransactionStatus.Failed).
I has been happening with both PayFlowPro and Custom Gateway.
I found an older post on the AC forum (
viewtopic.php?f=42&t=8767&start=0&hilit ... ess#p37630) where it is mentioned as a default behavior.
Is it still the case with version 7.0.4 ??
In what cases the flag will be false ??
Appreciate any help on this.
Thanks.
Code: Select all
if (checkOut)
{
//PROCESS THE CHECKOUT
CheckoutRequest checkoutRequest = new CheckoutRequest(payment);
CheckoutResponse checkoutResponse = Token.Instance.User.Basket.Checkout(checkoutRequest);
if (checkoutResponse.Success) // Success Flag Is True almost Always.
{
if (CheckedOut != null) CheckedOut(this, new CheckedOutEventArgs(checkoutResponse));
Response.Redirect(NavigationHelper.GetReceiptUrl(checkoutResponse.OrderId));
}
else
{
//...
}
}
Re: CheckoutResponse.Success 'True' even with failed Transaction
Posted: Tue Mar 30, 2010 7:33 am
by mazhar
Yes this behavior is same and application will create an order even if the payments get failed. checkoutResponse.Success can return false if basket contains some invalid item and upon checkout it fails the validate procedure mean has something in it that can't be placed in this order. In this case it will return false and no order will be created.
Re: CheckoutResponse.Success 'True' even with failed Transaction
Posted: Tue Mar 30, 2010 10:45 am
by Diavan
Thanks for the reply Mazhar.
I am just wondering about why this behavior is implemented by default.
I am not sure if I have see any online shopping site which would have this sort of functionality, especially on Credit Card Authorization failure.
I would rather show the generated Transaction Error message to the customer and have them proceed to order submission via a different method ex. phone call.
Is there any way around it? There is just too much confusion among the site customers with this behavior.
Would really really appreciate a solution.
Thanks.
Re: CheckoutResponse.Success 'True' even with failed Transaction
Posted: Tue Mar 30, 2010 10:50 am
by mazhar
In fact this because to make sure that merchants are not losing sales. You can consider the case where some time payment provider is down for some reason and customers been not able to place orders. Yes there is a way to let the customer know their payment failed and they should retry to clear their payments. You need to turn on the failed payment handling upon Receipt page. Login to merchant side got receipt page scriptlet edit it and then turn on the failed payment handling like
Code: Select all
[[ConLib:RecieptPage HandleFailedPayments="true"]]
Re: CheckoutResponse.Success 'True' even with failed Transaction
Posted: Tue Mar 30, 2010 11:13 am
by Diavan
The suggested flag "HandleFailedPayments" will work for our needs.
I would, however, request this to be optional in the future releases, if possible.
Re: CheckoutResponse.Success 'True' even with failed Transaction
Posted: Tue Mar 30, 2010 12:05 pm
by butterscotch
I agree with Diavan's request as well, hopefully you can make this optional rather than default, for me it was also hard to get around this idea.
Re: CheckoutResponse.Success 'True' even with failed Transaction
Posted: Fri Jul 23, 2010 12:55 pm
by 1234567890
I make the sugggested changes by AC tech support and still having issue. The failed transaction still go through.
I change the script on My Order Page to the following:
[[ConLib:MyOrderPage HandleFailedPayments="true"]]
I change the script on Receipt Page to the following:
[[ConLib:ReceiptPage HandleFailedPayments="true"]]