Jump to content

Infinite Product Quantity Possible?


Recommended Posts

Hi all, just downloaded ps & host it on my local pc for a test run. I'm satisfied with most of the features, but there is one very important feature that I need but is missing on ps. Is it possible to set stock level as infinite? For eg, Stock levels for certain product category is going to be infinite & on the front page, customer can buy up to 40 x unit each time? Thanks for any helps provided :)

Link to comment
Share on other sites

This can't be done using the Back Office. This can only be done by modifying code. I've done it before, but it was a lot of work. You need to set the quantity of all products to 40, then comment out the contents of the updateQuantity function in classes/Product.php, leaving only the first if statement and return true. Do the same with the reinjectQuantities function. This means that the quantity will always be 40 and will not change when products are bought or returned. If the customer tries to add more than 40 of a single product to the cart, it will display an error message, since only 40 are available. Let me know if this works for you. There might be another couple of checks you have disable to get it to work.

You will also need to change the <!-- number of item in stock --> section of product.tpl in your theme directory so that it says "Maximum quantity: 40" instead of "40 items in stock".

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