PluginUs.Net - Business Tools for WooCommerce and WordPress

[realize your idea - make your dreams come true]

Support Forum

You need to log-in to create request (topic) to the support

In Stock, Out of Stock, On backorder icons

The support doesn work on Saturdays and Sundays, so some Friday requests can be answered on Monday. If you have problems with registration ask help on contact us page please
If you not got email within 24~36 business hours, firstly check your spam box, and if no any email from the support there - back to the forum and read answer here. DO NOT ANSWER ON EMAILS [noreply@pluginus.net] FROM THE FORUM!! Emails are just for your info, all answers should be published only here.
The support doesn work on Saturdays and Sundays, so some Friday requests can be answered on Monday.

Hello, when I don't allow stock managment I have three stock options (In Stock, Out of Stock, On backorder) but when I make a product table, there are just two status (icon) yes(green) and no(red), and my customers

don't see if something is on backorder, but they can buy it (it's ok) without any notice. How can I show in tables that something can be ordered, but its staus is on backorder?

Thanks in advanced!!!

Hello

Please  try  to  use  a  hook  to  override html  of "stock status"

An  example:

add_filter('woot_profile_extend', function($fields, $action, $shortcode_args){
if(isset($fields['stock_status']) && isset($fields['stock_status']['action'])){
$fields['stock_status']['action'] = function ($post_id) {
$product = wc_get_product($post_id);
$selected_status = $product->get_stock_status();
//$status = wc_get_product_stock_status_options()[$selected_status];

$mark ="<span class='woot-html-cross'><i class='woot-icon'></i></span>";

if ('instock' == $selected_status) {
$mark ="<span class='woot-html-check'><i class='woot-icon'></i></span>";
} elseif ('onbackorder' == $selected_status){
$mark ="<span class='woot-html-check'>ADD ANY TEXT</span>";
}

return $mark;
};
}
return $fields;
},33,3);

Works perfectly fine!!! Thank you!

hello

Great!  Welcome;)