// Small fix

git-svn-id: http://dev.prestashop.com/svn/v1/branches/1.5.x@16981 b9a71923-0436-4b27-9f14-aed3839534dd
This commit is contained in:
rGaillard
2012-08-23 17:42:34 +00:00
parent 4e4576ec97
commit 0489bf4945
+2 -1
View File
@@ -2147,8 +2147,9 @@ class ProductCore extends ObjectModel
$ret = array();
$row = Db::getInstance(_PS_USE_SQL_SLAVE_)->executeS('
SELECT cp.`id_category`, cl.`name`, cl.`link_rewrite` FROM `'._DB_PREFIX_.'category_product` cp
LEFT JOIN `'._DB_PREFIX_.'category` c ON (c.id_category = cp.id_category)
LEFT JOIN `'._DB_PREFIX_.'category_lang` cl ON (cp.`id_category` = cl.`id_category`'.Shop::addSqlRestrictionOnLang('cl').')
'.Shop::addSqlAssociation('category', 'cp').'
'.Shop::addSqlAssociation('category', 'c').'
WHERE cp.`id_product` = '.(int)$id_product.'
AND cl.`id_lang` = '.(int)$id_lang
);