Can Zen Cart shopping cart "reserve" store items for fixed amount of time?
I'm considering ZC for my next store implementation. Here's a question I didn't see answered in the Features FAQ:
Can Zen Cart shopping cart "reserve" store items for fixed amount of time?
This is important in my application area. My main competitor has this implemented.
Re: Can Zen Cart shopping cart "reserve" store items for fixed amount of time?
Out of the box - no. Early bird gets the worm.
Plugin available - not that I know of.
And now for the line I hate most of the time - yes, it can be done with some custom code. The logic behind it is not *that* complex, especially if there are no attributes (ZC terminology for options) involved. If you're using attributes and each attribute has it's own stock, you'll be needing the Stock by Attributes plugin and this is where the custom code will probably get very tricky, but still doable...
Re: Can Zen Cart shopping cart "reserve" store items for fixed amount of time?
Thank you for the quick reply, and also the phrase "Early bird gets the worm".
Re: Can Zen Cart shopping cart "reserve" store items for fixed amount of time?
If your expected volume is low to moderate, you might even do some of this manually to prove out the concept. For example, you could use Ask a Question to do this. Alternately, to get them to put some skin in the game, you could sell "reserve for 48 hours (or whatever)" as a product for a nominal cost. In both cases you'd do the stock adjustment (down - and up if they bail out) by hand. Good luck!
Re: Can Zen Cart shopping cart "reserve" store items for fixed amount of time?
@swguy
It's either supported or it's not, and I'm happy with either answer.
Re: Can Zen Cart shopping cart "reserve" store items for fixed amount of time?
Quote:
Originally Posted by
balihr
Early bird gets the worm.
About the "out of the box" shopping cart:
Suppose 3+ customers have the last of the same item in their cart and they all press "purchase" in < 1s of each other. Could I end up with multiple purchases of that last item?
Re: Can Zen Cart shopping cart "reserve" store items for fixed amount of time?
The stock gets deducted AFTER an order is placed. If you have one last item in stock, you can have 10 people placing it in their carts at the same time. In theory, this scenario could happen within 24 minutes, not just <1 sec...
The final stock check runs when customer gets to checkout_confirmation page. Once on that page, there's no more checks. This means that if all 10 customers get to the checkout_confirmation page before either one places the order, they can all place the order. I might be bad at explaining things, so let's put it this way: customer1 gets to checkout_confirmation page. He's checking all the data entered, gets distracted by the dog barking and walks to the door. Customer2 gets to checkout_confirmation, is about to place the order, but gets a phone call and answers it. Customer3 gets to checkout_confirmation, says it's all good and places the order. Your last item just sold out. Customer1 comes back to the computer, his session is still active (24 minutes before automated timeout), he checks everything, is happy and places the order successfully. Customer2 hangs up the phone and clicks the button and places the order successfully. You just sold your last item to 3 different people...
@swguy - possible room for improvement for next release to add the stock check to checkout_process.php ?
Re: Can Zen Cart shopping cart "reserve" store items for fixed amount of time?
There are a lot of checks to prevent this. I don't believe the scenario you are describing actually happens that way in 1.5.8.
Re: Can Zen Cart shopping cart "reserve" store items for fixed amount of time?
Ok, thank you for the candid reply. It's a "feature" of many carts! As you seem to be aware, the "purchase" operation 1st needs to attempt to decrement the non-negative SQL inventory counter for each item and take appropriate action on the success / failure of each.
My scenario: a popular item comes back in stock in limited supply (1 to 3). The notification list gets sent out. 15 minutes later 100 people have it in their cart and check out nearly simultaneously. I'd personally rather not manually process 99 refunds.
So I will check for a possible update in the coming weeks or few months. I won't start implementation until then anyway.
Re: Can Zen Cart shopping cart "reserve" store items for fixed amount of time?
Quote:
Originally Posted by
swguy
There are a lot of checks to prevent this. I don't believe the scenario you are describing actually happens that way in 1.5.8.
Sadly, it does. Just tested on a vanilla 1.5.8 with demo data.
admin->Configuration->Stock->Allow Checkout->false
product = Die Hard With A Vengeance Linked (id 12) - updated stock to 1
Using account_1 in Firefox, put product in cart, got to checkout_confirmation page.
Using account_2 in Chrome, did same as above.
(at this point, 2 different accounts in 2 different browsers both have the exact same item in cart)
Placed order with account_1, switched over to Chrome and placed order with account_2.
Product status was changed to 0, quantity is -1.