[-] BO : Fixed potential errors with untranslated admin tabs #PSCFV-8104
This commit is contained in:
1 parent
5976a471a7
commit
3a02d6f281
1 file changed
+2
-1
+2
-1
@@ -237,8 +237,9 @@ class TabCore extends ObjectModel
|
|||||||
if (!isset(self::$_cache_tabs[$id_lang]))
|
if (!isset(self::$_cache_tabs[$id_lang]))
|
||||||
{
|
{
|
||||||
self::$_cache_tabs[$id_lang] = array();
|
self::$_cache_tabs[$id_lang] = array();
|
||||||
|
// Keep t.*, tl.name instead of only * because if translations are missing, the join on tab_lang will overwrite the id_tab in the results
|
||||||
$result = Db::getInstance(_PS_USE_SQL_SLAVE_)->executeS('
|
$result = Db::getInstance(_PS_USE_SQL_SLAVE_)->executeS('
|
||||||
SELECT *
|
SELECT t.*, tl.name
|
||||||
FROM `'._DB_PREFIX_.'tab` t
|
FROM `'._DB_PREFIX_.'tab` t
|
||||||
LEFT JOIN `'._DB_PREFIX_.'tab_lang` tl ON (t.`id_tab` = tl.`id_tab` AND tl.`id_lang` = '.(int)$id_lang.')
|
LEFT JOIN `'._DB_PREFIX_.'tab_lang` tl ON (t.`id_tab` = tl.`id_tab` AND tl.`id_lang` = '.(int)$id_lang.')
|
||||||
ORDER BY t.`position` ASC');
|
ORDER BY t.`position` ASC');
|
||||||
|
|||||||
Reference in new issue
Block a user