[-] FO: Fix links to products_attribute when custom url is defined with the blocklayered
This commit is contained in:
1 parent
c6d9d9c94e
commit
6afcee4b88
1 file changed
+3
-1
+3
-1
@@ -4737,7 +4737,8 @@ class ProductCore extends ObjectModel
|
|||||||
LEFT JOIN `'._DB_PREFIX_.'layered_indexable_attribute_lang_value` la
|
LEFT JOIN `'._DB_PREFIX_.'layered_indexable_attribute_lang_value` la
|
||||||
ON (la.`id_attribute` = a.`id_attribute` AND la.`id_lang` = '.(int)Context::getContext()->language->id.')
|
ON (la.`id_attribute` = a.`id_attribute` AND la.`id_lang` = '.(int)Context::getContext()->language->id.')
|
||||||
WHERE la.`url_name` IS NOT NULL AND la.`url_name` != \'\'
|
WHERE la.`url_name` IS NOT NULL AND la.`url_name` != \'\'
|
||||||
AND pa.`id_product` = '.(int)$id_product);
|
AND pa.`id_product` = '.(int)$id_product.'
|
||||||
|
AND pac.`id_product_attribute` = '.(int)$id_product_attribute);
|
||||||
|
|
||||||
if (!empty($nb_custom_values))
|
if (!empty($nb_custom_values))
|
||||||
{
|
{
|
||||||
@@ -4780,6 +4781,7 @@ class ProductCore extends ObjectModel
|
|||||||
ON (pac.`id_product_attribute` = pa.`id_product_attribute`)
|
ON (pac.`id_product_attribute` = pa.`id_product_attribute`)
|
||||||
'.Shop::addSqlAssociation('product_attribute', 'pa').'
|
'.Shop::addSqlAssociation('product_attribute', 'pa').'
|
||||||
WHERE pa.`id_product` = '.(int)$id_product.'
|
WHERE pa.`id_product` = '.(int)$id_product.'
|
||||||
|
AND pac.id_product_attribute = '.(int)$id_product_attribute.'
|
||||||
AND a.`id_attribute` NOT IN('.implode(', ', $tab_id_attribute).')');
|
AND a.`id_attribute` NOT IN('.implode(', ', $tab_id_attribute).')');
|
||||||
$result = array_merge($values_not_custom, $result);
|
$result = array_merge($values_not_custom, $result);
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in new issue
Block a user