Jump to content

Reduce stock only after payment?


Eutanasio

Recommended Posts

Hi,

I don't want PS to diminish the available stock for any order processed on the website, 90% of them are just fake.

 

How can I do to make PS subtract the stock only when the status of an order is changed to "Payment accepted" or "Advance payment accepted"?

Thanks

Link to comment
Share on other sites

You may need to override validateOrder() function of PaymentModule class and also modify changeIdOrderState() function of OrderHistory class.  

Inside this function you can find code related to stock management and you will need to modify that based on your own need.

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...