[-] BO : BugFix : #PSTEST-431 : replacing modules names with translated modules names in AdminAccess
git-svn-id: http://dev.prestashop.com/svn/v1/branches/1.5.x@12402 b9a71923-0436-4b27-9f14-aed3839534dd
This commit is contained in:
@@ -67,6 +67,7 @@ class AdminAccessControllerCore extends AdminController
|
|||||||
|
|
||||||
$modules = array();
|
$modules = array();
|
||||||
foreach ($profiles as $profile)
|
foreach ($profiles as $profile)
|
||||||
|
{
|
||||||
$modules[$profile['id_profile']] = Db::getInstance(_PS_USE_SQL_SLAVE_)->executeS('
|
$modules[$profile['id_profile']] = Db::getInstance(_PS_USE_SQL_SLAVE_)->executeS('
|
||||||
SELECT ma.`id_module`, m.`name`, ma.`view`, ma.`configure`
|
SELECT ma.`id_module`, m.`name`, ma.`view`, ma.`configure`
|
||||||
FROM '._DB_PREFIX_.'module_access ma
|
FROM '._DB_PREFIX_.'module_access ma
|
||||||
@@ -75,6 +76,12 @@ class AdminAccessControllerCore extends AdminController
|
|||||||
WHERE id_profile = '.(int)$profile['id_profile'].'
|
WHERE id_profile = '.(int)$profile['id_profile'].'
|
||||||
ORDER BY m.name
|
ORDER BY m.name
|
||||||
');
|
');
|
||||||
|
foreach ($modules[$profile['id_profile']] as &$module)
|
||||||
|
{
|
||||||
|
$m = Module::getInstanceById($module['id_module']);
|
||||||
|
$module['name'] = $m->displayName;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
$this->fields_form = array('');
|
$this->fields_form = array('');
|
||||||
$this->tpl_form_vars = array(
|
$this->tpl_form_vars = array(
|
||||||
|
|||||||
Reference in New Issue
Block a user