View Issue Details

IDProjectCategoryView StatusLast Update
1642Composrshoppingpublic2014-05-29 22:29
ReporterGuest Assigned ToGuest  
PrioritynormalSeverityminor 
Status resolvedResolutionfixed 
Summary1642: Shopping Cart does not update stock correctly when cleared.
DescriptionAny one that adds, then deletes a product from their shopping cart, puts that product into an awaiting transaction status, preventing others from purchasing it. The product is stuck there, until I go and cancel non-completed orders. The same thing happens when a user goes to Paypal, then abandons the purchase.
Steps To ReproduceAdd a product to your shopping cart. Then clear your cart, then do it again. Do it as many times as you have product stock, and it will lock out new purchases, without any users ever even trying to actually buy anything.

You can defeat this problem by setting stock to "maintained", but now you are selling items you may not have on hand and that may have a long lead time.
TagsNo tags attached.
Attach Tags
Attached Files
Time estimation (hours)
Sponsorship open

Sponsor

Date Added Member Amount Sponsored

Activities

Chris Graham

2014-05-29 22:28

administrator   ~2153

Last edited: 2014-05-29 22:29

Automated response: Stock control can get locked up

The shopping cart does not do a good job of clearing out orders that are never completed. This includes intermediate orders when managing the shopping cart.

This locks up stock control.

This is a bit complex to clean up as we have to also avoid over-sales, and the potential for clearing out orders that are currently being purchased if the user accidentally refreshes their cart in another tab.

We will have to assume that payment signals (IPNs) are truly instant or that customers won't come in and create a new cart while waiting for a prior order's IPN to come through. This assumption is better than locking up the stock unnecessarily.

Chris Graham

2014-05-29 22:28

administrator   ~2154

Fixed in git commit 77d6d9f (https://github.com/chrisgraham/Composr/commit/77d6d9f - link will become active once code pushed)

A hotfix (a TAR of files to upload) have been uploaded to this issue. These files are made to the latest intra-version state (i.e. may roll in earlier fixes too if made to the same files) - so only upload files newer than what you have already. Always take backups of files you are replacing or keep a copy of the manual installer for your version, and only apply fixes you need. These hotfixes are not necessarily reliable or well supported. Not sure how to extract TAR files to your Windows computer? Try 7-zip (http://www.7-zip.org/).

Chris Graham

2014-05-29 22:29

administrator   ~2155

FYI orders only stay locked in for a day, after that it assumes they aren't going to be purchased and stock is returned to availability. We'll make the timing configurable in v10.

Issue History

Date Modified Username Field Change