Need to Capture the Order after submit

For general questions and discussions specific to the AbleCommerce 7.0 Asp.Net product.
Post Reply
BillEisenman
Ensign (ENS)
Ensign (ENS)
Posts: 4
Joined: Fri Oct 24, 2008 2:55 pm

Need to Capture the Order after submit

Post by BillEisenman » Fri Oct 24, 2008 3:30 pm

Where exactly does the order get sent to the DB. I need to capture it and sent it to our Order Processing DB also.

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

Re: Need to Capture the Order after submit

Post by AbleMods » Fri Oct 24, 2008 7:39 pm

BillEisenman wrote:Where exactly does the order get sent to the DB. I need to capture it and sent it to our Order Processing DB also.
Not sure precisely what you mean by "where" other than the obvious. The order is stored during the checkout process. The checkout page code is located in the ~/ConLib/OnePageCheckout.ascx user control.

Storing an order is actually performed via the basket instance calling a compiled method. It's not something you can interact with without full source code as it's part of the CommerceBuilder API.

You're probably better off retrieving the order AFTER checkout is complete within the ~/Checkout/Receipt.aspx page. At that point all Able code has acted upon the basket and the order has been stored to the Able db.
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

BillEisenman
Ensign (ENS)
Ensign (ENS)
Posts: 4
Joined: Fri Oct 24, 2008 2:55 pm

Re: Need to Capture the Order after submit

Post by BillEisenman » Sat Oct 25, 2008 6:08 am

It is as I expected. I have already created stored procedures in the ac7 db to retrieve the information that I need. I still would rather get it live though. Do you think that AbleCommerce would allow me access to thee code for customization?

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

Re: Need to Capture the Order after submit

Post by AbleMods » Sat Oct 25, 2008 10:41 am

BillEisenman wrote:It is as I expected. I have already created stored procedures in the ac7 db to retrieve the information that I need. I still would rather get it live though. Do you think that AbleCommerce would allow me access to thee code for customization?
I almost never go straight to the database. The CommerceBuilder data classes have alot of additional functionality that doesn't exist in the db.

The API source code is available for purchase. Just contact Able and they'll be happy to discuss it with you.
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

afm
Captain (CAPT)
Captain (CAPT)
Posts: 339
Joined: Thu Nov 03, 2005 11:52 pm
Location: Portland, OR
Contact:

Re: Need to Capture the Order after submit

Post by afm » Sat Oct 25, 2008 11:32 am

BillEisenman wrote:Where exactly does the order get sent to the DB. I need to capture it and sent it to our Order Processing DB also.
The basket is converted to an order in the PaymentForms (i.e. \Checkout\PaymentForms\CreditCardPaymentForm.ascx). It looks pretty easy to capture the order:

Code: Select all

CheckoutResponse checkoutResponse = Token.Instance.User.Basket.Checkout(checkoutRequest);
if (checkoutResponse.Success)
{
    // Insert code to capture order here [i.e. CaptureOrder(checkoutResponse.OrderId);]
    if (CheckedOut != null) CheckedOut(this, new CheckedOutEventArgs(checkoutResponse.OrderId));
    Response.Redirect(NavigationHelper.GetReceiptUrl(checkoutResponse.OrderId));
}
Andy Miller
Structured Solutions

Shipper 3 - High Velocity Shipment Processing

BillEisenman
Ensign (ENS)
Ensign (ENS)
Posts: 4
Joined: Fri Oct 24, 2008 2:55 pm

Re: Need to Capture the Order after submit

Post by BillEisenman » Sat Oct 25, 2008 11:49 am

Thank you very much for your insight Andy. I will try it later this weekend or on Monday.

Post Reply