Custom Checkout Issues...

For general questions and discussions specific to the AbleCommerce 7.0 Asp.Net product.
Post Reply
User avatar
page8workaholic
Ensign (ENS)
Ensign (ENS)
Posts: 4
Joined: Sat Sep 12, 2009 2:42 pm
Location: Texas

Custom Checkout Issues...

Post by page8workaholic » Sat Sep 12, 2009 2:54 pm

I'm currently working on a site that requires that an order be authorized and captured before the user is allow to download a digital product. We are wanting the process to be automatic, so I've created a copy of the default CreditCardPaymentForm and have made the following adjustment to check that the order has indeed been captured before moving on to perform additional tasks. The problem is that though the checkout comes back as a success the payment object has a status of AuthorizationFailed. I know that the CC is good too, and the gateway is set to authorize & capture. Can anyone shed some light on what may be happening that would cause the CheckoutResponse to return successful, but the payment method not be captured?

*note: Another strange thing that I noticed is that Authorize.net isn't generating a authorization code, so it is as if the system isn't pushing over all the needed information. From what I can see on the transaction on Authorize.net's side everything except for the authorization code is there.

Code: Select all

            //CREATE THE PAYMENT OBJECT
            Payment payment = GetPayment();
            
            //PROCESS CHECKING OUT EVENT
            bool checkOut = true;
            if (CheckingOut != null)
            {
                CheckingOutEventArgs c = new CheckingOutEventArgs(payment);
                CheckingOut(this, c);
                checkOut = !c.Cancel;
            }
            if (checkOut)
            {
                //PROCESS A CHECKOUT
                CheckoutRequest checkoutRequest = new CheckoutRequest(payment);
                CheckoutResponse checkoutResponse = Token.Instance.User.Basket.Checkout(checkoutRequest);
                if (checkoutResponse.Success)
                {
                    if (CheckedOut != null)
                        CheckedOut(this, new CheckedOutEventArgs(checkoutResponse));

                    #region PAGE8 CUSTOM CODE
                    // BEGIN PAGE8 CUSTOM CODE --------------------------------------------------------------

                    if (payment.PaymentStatus == PaymentStatus.Captured)
Jackie Apshire Jr.
Page8studios.com


Desire without dedication is simply dreaming...

User avatar
AbleMods
Master Yoda
Master Yoda
Posts: 5170
Joined: Wed Sep 26, 2007 5:47 am
Location: Fort Myers, Florida USA

Re: Custom Checkout Issues...

Post by AbleMods » Mon Sep 14, 2009 6:08 am

page8workaholic wrote:I'm currently working on a site that requires that an order be authorized and captured before the user is allow to download a digital product.
AC7 already supports this scenario. Set the payment gateway to Authorize/Capture mode and set the digital good to Activate on Full Payment.
Joe Payne
AbleCommerce Custom Programming and Modules http://www.AbleMods.com/
AbleCommerce Hosting http://www.AbleModsHosting.com/
Precise Fishing and Hunting Time Tables http://www.Solunar.com

Post Reply