Page 1 of 1

How to avoid create a new order when a payment is refused

Posted: 04 Nov 2018, 10:07
by sixbynine
Hello,

I wonder if it would be possible, when the payment for an order is first refused, instead of creating a new order ID to use the same order ID again when the customer is trying to pay it again (with the button TRY AGAIN).

I ask that because it is complicated to manage the stock levels with this default behaviour. In my country, credit card transactions are protected with a 3D secure code that is often mis-typed by the customers leading easily to a few "refused" orders before having one accepted.

Thank you very much,

sbn

Re: How to avoid create a new order when a payment is refuse

Posted: 05 Nov 2018, 21:47
by aimeos
It might be possible if you add this but there may be side effects:
https://github.com/aimeos/ai-controller ... b34e8f525c

Can you please test yourself, escpecially what happens if the basket is changed after clicking on "change payment"?

Nevertheless, it won't solve your problem because product stock is blocked by the order item, not the order base item. You have to execute the "order/cleanup/unpaid" and "order/cleanup/unfinished" job controllers regularly to release the stock and used coupons.