woocommerce-cart-stock-reducer icon indicating copy to clipboard operation
woocommerce-cart-stock-reducer copied to clipboard

Allow backorders on in stock products

Open jamesgol opened this issue 5 years ago • 5 comments

Feature request from WordPress forums. https://wordpress.org/support/topic/allow-backorders/

jamesgol avatar Apr 09 '19 15:04 jamesgol

Very much interested in this option too. So we can show longer delivery days when stock is zero OR below zero. See that this was requested like 11 months ago. So not sure if this is every going to happen.

jasperf avatar Mar 04 '20 07:03 jasperf

@jasperf The plugin already supports backorder items, they just have to be completely out of stock in order to backorder.

What is it you want to adjust? There's probably a filter you can use to adjust this.

jamesgol avatar Mar 04 '20 17:03 jamesgol

Well I was looking for an option to show 1-2 days when in stock and 2-4 days when out of stock. A user at SO mentioned your plugin to allow stock reduction with items in cart and that would allow me to use a trigger on the product page or checkout showing out of stock option even before the payment has been made. The customers can however order more than is in stock so that has to work. So if they do a 10 products backorder I still want to show 2-4 days.

See https://stackoverflow.com/questions/60520230/product-stock-quantity-no-of-products-in-cart where I asked a question on this and the check / shortcode I had tried. As for filters, well, if you do have a filter based on your plugin to show something/text when cart quantity reduces stock to zero or below that would be great.

jasperf avatar Mar 05 '20 00:03 jasperf

Have you tried your shortcode solution with this plugin? It should cause your is_in_stock() call to return based on the virtual stock quantity. Though there is the potential for the backorder issue.

I'm not sure you really need this plugin, it looks like with your shortcode and/or the snippet someone else posted it should get to where you need to be.

The filter I was referring to would just have been one to change the text displayed, but it looks like you must have modified your theme to add the shortcode or something so you wouldn't need a filter/action.

jamesgol avatar Mar 05 '20 02:03 jamesgol

I'm not sure you really need this plugin, it looks like with your shortcode and/or the snippet someone else posted it should get to where you need to be.

Yeah, I will try that solution first some more.

The filter I was referring to would just have been one to change the text displayed, but it looks like you must have modified your theme to add the shortcode or something so you wouldn't need a filter/action.

Well the shortcode does the filterwork already, but did it based on real in stock quantity so did not catch changes in cart, but with answer given I should be able to adjust my filter and shortcode using that filter. Thanks for your feedback @jamesgol . I really appreciate it. And also good to hear backorders do work already with your plugin.!

jasperf avatar Mar 05 '20 02:03 jasperf