Jump to content

Need order id before validateOrder


kanasaikuat

Recommended Posts

Hi there, i'm trying to develop a payment gateway for my current store. What my understanding is, prestashop create the order via validateOrder method after payment was completed.

 

This is not i want to be in my current store. What i need is:

1. Customer select payment method.

2. Create order with pending status.

3. Redirect user to certain bank payment page (i already has the bank payment gateway).

4. User key in payment details on bank payment page.

5. Redirect customer to thank you page and at the same time update order status to complete.

 

I need the order id before validateOrder, so that i am able to track which order has redirected to bank payment page but failed to return.

 

Anyone able to tell me how can i do this on prestashop?

Link to comment
Share on other sites

We just ran a check for all carts that have products in them, that don't have a corresponding order after X amount of time. That worked fine for the purposes of asking if they had a problem.

 

If you specifically need to track ones which got to the payment gateway, then you'd need to add in a custom flag on the cart to record that

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...