// Replace shop->sqlAsso(), shop->sqlLang() and shop->sqlRestriction() with shop->addSqlAssociation(), shop->addSqlRestrictionOnLang() and shop->addSqlRestriction()
This commit is contained in:
@@ -203,7 +203,7 @@ class Secuvad_flux
|
||||
FROM `'._DB_PREFIX_.'secuvad_assoc_category` sac
|
||||
JOIN `'._DB_PREFIX_.'category_product` cp ON (cp.`id_category` = sac.`id_category`)
|
||||
JOIN `'._DB_PREFIX_.'category` c ON (c.`id_category` = cp.`id_category`)
|
||||
JOIN `'._DB_PREFIX_.'product_lang` pl ON (cp.`id_product` = pl.`id_product`'.$this->context->shop->sqlLang('pl').')
|
||||
JOIN `'._DB_PREFIX_.'product_lang` pl ON (cp.`id_product` = pl.`id_product`'.$this->context->shop->addSqlRestrictionOnLang('pl').')
|
||||
JOIN `'._DB_PREFIX_.'lang` l ON (l.`id_lang` = pl.`id_lang` AND l.`id_lang` = '.(int)Context::getContext()->language->id.')
|
||||
WHERE pl.`id_product` = '.(int)($product['product_id']).'
|
||||
ORDER BY c.`level_depth` DESC
|
||||
|
||||
@@ -1109,7 +1109,7 @@ class Secuvad extends Module
|
||||
$module_not_assoc = Db::getInstance()->executeS('
|
||||
SELECT cl.`name`, c.`id_category`
|
||||
FROM `'._DB_PREFIX_.'category` c
|
||||
JOIN `'._DB_PREFIX_.'category_lang` cl ON (cl.`id_category` = c.`id_category`'.$this->context->shop->sqlLang('cl').')
|
||||
JOIN `'._DB_PREFIX_.'category_lang` cl ON (cl.`id_category` = c.`id_category`'.$this->context->shop->addSqlRestrictionOnLang('cl').')
|
||||
JOIN `'._DB_PREFIX_.'lang` l ON (l.`id_lang` = cl.`id_lang` AND l.`iso_code` = \'en\')
|
||||
JOIN `'._DB_PREFIX_.'secuvad_assoc_category` sac ON (sac.`id_category` = c.`id_category`)
|
||||
LEFT JOIN `'._DB_PREFIX_.'secuvad_category` sc ON (sc.`category_id` = sac.`category_id` AND sc.`id_lang` = '.(int)$this->context->language->id.')
|
||||
|
||||
Reference in New Issue
Block a user