Dashboard: Fixes # of "out of stock" products

Use woocommerce_notify_no_stock_amount rather than woocommerce_notify_low_stock_amount to count out of stock products
This commit is contained in:
tamarazuk 2014-02-14 00:06:30 -05:00 committed by Coen Jacobs
parent 5fd62e202a
commit 6f4a91e36e
1 changed files with 1 additions and 1 deletions

View File

@ -116,7 +116,7 @@ class WC_Admin_Dashboard {
AND posts.post_type IN ('product', 'product_variation') AND posts.post_type IN ('product', 'product_variation')
AND posts.post_status = 'publish' AND posts.post_status = 'publish'
AND ( AND (
postmeta.meta_key = '_stock' AND CAST(postmeta.meta_value AS SIGNED) <= '{$stock}' AND postmeta.meta_value != '' postmeta.meta_key = '_stock' AND CAST(postmeta.meta_value AS SIGNED) <= '{$nostock}' AND postmeta.meta_value != ''
) )
AND ( AND (
( postmeta2.meta_key = '_manage_stock' AND postmeta2.meta_value = 'yes' ) OR ( posts.post_type = 'product_variation' ) ( postmeta2.meta_key = '_manage_stock' AND postmeta2.meta_value = 'yes' ) OR ( posts.post_type = 'product_variation' )