// Some fix on multishop + stock

git-svn-id: http://dev.prestashop.com/svn/v1/branches/1.5.x@10564 b9a71923-0436-4b27-9f14-aed3839534dd
This commit is contained in:
rMalie
2011-11-23 17:00:20 +00:00
parent 38d17b447e
commit e4654570e9
6 changed files with 16 additions and 19 deletions
+1 -4
View File
@@ -596,7 +596,7 @@ class CategoryCore extends ObjectModel
return (int)Db::getInstance(_PS_USE_SQL_SLAVE_)->getValue($sql);
}
$sql = 'SELECT p.*, sa.out_of_stock, stock.quantity, pa.`id_product_attribute`, pl.`description`, pl.`description_short`, pl.`available_now`,
$sql = 'SELECT p.*, stock.out_of_stock, stock.quantity, pa.`id_product_attribute`, pl.`description`, pl.`description_short`, pl.`available_now`,
pl.`available_later`, pl.`link_rewrite`, pl.`meta_description`, pl.`meta_keywords`, pl.`meta_title`, pl.`name`, i.`id_image`,
il.`legend`, m.`name` AS manufacturer_name, tl.`name` AS tax_name, t.`rate`, cl.`name` AS category_default,
DATEDIFF(p.`date_add`, DATE_SUB(NOW(),
@@ -634,9 +634,6 @@ class CategoryCore extends ObjectModel
AND tl.`id_lang` = '.(int)$id_lang.')
LEFT JOIN `'._DB_PREFIX_.'manufacturer` m
ON m.`id_manufacturer` = p.`id_manufacturer`
LEFT JOIN `'._DB_PREFIX_.'stock_available` sa
ON sa.`id_product` = p.`id_product`
AND sa.id_product_attribute = 0
WHERE cp.`id_category` = '.(int)$this->id
.($active ? ' AND p.`active` = 1' : '')
.($id_supplier ? ' AND p.id_supplier = '.(int)$id_supplier : '').