// Fix "home" permissions
git-svn-id: http://dev.prestashop.com/svn/v1/branches/1.5.x@12396 b9a71923-0436-4b27-9f14-aed3839534dd
This commit is contained in:
@@ -2559,8 +2559,11 @@ class AdminControllerCore extends Controller
|
|||||||
*/
|
*/
|
||||||
public function createTemplate($tpl_name)
|
public function createTemplate($tpl_name)
|
||||||
{
|
{
|
||||||
// Overrides exists?
|
// Use override tpl if it exists
|
||||||
if ($this->override_folder && file_exists($this->context->smarty->getTemplateDir(0).'controllers/'.$this->override_folder.$tpl_name))
|
// If view access is denied, we want to use the default template that will be used to display an error
|
||||||
|
if ($this->viewAccess()
|
||||||
|
&& $this->override_folder
|
||||||
|
&& file_exists($this->context->smarty->getTemplateDir(0).'controllers/'.$this->override_folder.$tpl_name))
|
||||||
return $this->context->smarty->createTemplate('controllers/'.$this->override_folder.$tpl_name, $this->context->smarty);
|
return $this->context->smarty->createTemplate('controllers/'.$this->override_folder.$tpl_name, $this->context->smarty);
|
||||||
|
|
||||||
return $this->context->smarty->createTemplate($this->context->smarty->getTemplateDir(0).$tpl_name, $this->context->smarty);
|
return $this->context->smarty->createTemplate($this->context->smarty->getTemplateDir(0).$tpl_name, $this->context->smarty);
|
||||||
|
|||||||
@@ -368,18 +368,6 @@ class AdminEmployeesControllerCore extends AdminController
|
|||||||
return parent::postProcess();
|
return parent::postProcess();
|
||||||
}
|
}
|
||||||
|
|
||||||
/*public function initProcess()
|
|
||||||
{
|
|
||||||
// If employee is editing its own entry, its ok
|
|
||||||
if ($this->tabAccess['edit'] !== '1'
|
|
||||||
&& $this->table == 'employee'
|
|
||||||
&& $this->context->employee->id == Tools::getValue('id_employee')
|
|
||||||
&& Tools::isSubmit('updateemployee'))
|
|
||||||
$this->tabAccess['edit'] = 1;
|
|
||||||
|
|
||||||
parent::initProcess();
|
|
||||||
}*/
|
|
||||||
|
|
||||||
public function initContent()
|
public function initContent()
|
||||||
{
|
{
|
||||||
if ($this->context->employee->id == Tools::getValue('id_employee'))
|
if ($this->context->employee->id == Tools::getValue('id_employee'))
|
||||||
|
|||||||
@@ -535,12 +535,10 @@ class AdminHomeControllerCore extends AdminController
|
|||||||
|
|
||||||
$this->warnDomainName();
|
$this->warnDomainName();
|
||||||
|
|
||||||
$tab = get_class();
|
|
||||||
$protocol = Tools::usingSecureMode()?'https':'http';
|
$protocol = Tools::usingSecureMode()?'https':'http';
|
||||||
$smarty->assign('protocol',$protocol);
|
$smarty->assign('protocol',$protocol);
|
||||||
$isoUser = $this->context->language->iso_code;
|
$isoUser = $this->context->language->iso_code;
|
||||||
$smarty->assign('isoUser',$isoUser);
|
$smarty->assign('isoUser',$isoUser);
|
||||||
$currency = $this->context->currency;
|
|
||||||
$upgrade = null;
|
$upgrade = null;
|
||||||
$tpl_vars['refresh_check_version'] = 0;
|
$tpl_vars['refresh_check_version'] = 0;
|
||||||
if (@ini_get('allow_url_fopen'))
|
if (@ini_get('allow_url_fopen'))
|
||||||
|
|||||||
Reference in New Issue
Block a user