[-] Core: ProductSale no more takes products with no visibility
Fixed bug that's ProductSale is taking products with no visibility, displaying them in module blockbestsellers. But as they have no visibility, we don't want to display them!
This commit is contained in:
1 parent
6b501dc409
commit
25675b8d38
1 file changed
+2
@@ -98,6 +98,7 @@ class ProductSaleCore
|
|||||||
LEFT JOIN `'._DB_PREFIX_.'tax` t ON (t.`id_tax` = tr.`id_tax`)
|
LEFT JOIN `'._DB_PREFIX_.'tax` t ON (t.`id_tax` = tr.`id_tax`)
|
||||||
'.Product::sqlStock('p').'
|
'.Product::sqlStock('p').'
|
||||||
WHERE product_shop.`active` = 1
|
WHERE product_shop.`active` = 1
|
||||||
|
AND p.`visibility` != \'none\'
|
||||||
AND p.`id_product` IN (
|
AND p.`id_product` IN (
|
||||||
SELECT cp.`id_product`
|
SELECT cp.`id_product`
|
||||||
FROM `'._DB_PREFIX_.'category_group` cg
|
FROM `'._DB_PREFIX_.'category_group` cg
|
||||||
@@ -150,6 +151,7 @@ class ProductSaleCore
|
|||||||
ON cl.`id_category` = product_shop.`id_category_default`
|
ON cl.`id_category` = product_shop.`id_category_default`
|
||||||
AND cl.`id_lang` = '.(int)$id_lang.Shop::addSqlRestrictionOnLang('cl').'
|
AND cl.`id_lang` = '.(int)$id_lang.Shop::addSqlRestrictionOnLang('cl').'
|
||||||
WHERE product_shop.`active` = 1
|
WHERE product_shop.`active` = 1
|
||||||
|
AND p.`visibility` != \'none\'
|
||||||
AND p.`id_product` IN (
|
AND p.`id_product` IN (
|
||||||
SELECT cp.`id_product`
|
SELECT cp.`id_product`
|
||||||
FROM `'._DB_PREFIX_.'category_group` cg
|
FROM `'._DB_PREFIX_.'category_group` cg
|
||||||
|
|||||||
Reference in new issue
Block a user