From fdd72b47fa4b1bce8734e09cbfd78516eab6de5d Mon Sep 17 00:00:00 2001 From: mMarinetti Date: Wed, 23 Nov 2011 18:36:59 +0000 Subject: [PATCH] // admincontroller fix when json git-svn-id: http://dev.prestashop.com/svn/v1/branches/1.5.x@10586 b9a71923-0436-4b27-9f14-aed3839534dd --- classes/AdminController.php | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/classes/AdminController.php b/classes/AdminController.php index 51a09b676..aa5cb06e6 100644 --- a/classes/AdminController.php +++ b/classes/AdminController.php @@ -261,6 +261,8 @@ class AdminControllerCore extends Controller 21 => $this->l('Module reset successfully'), 22 => $this->l('Module deleted successfully'), 23 => $this->l('Localization pack imported successfully'), 24 => $this->l('Refund Successful'), 25 => $this->l('Images successfully moved'), + 26 => $this->l('Cover selection saved'), + 27 => $this->l('Image shop association modified'), ); if (!$this->identifier) $this->identifier = 'id_'.$this->table; if (!$this->_defaultOrderBy) $this->_defaultOrderBy = $this->identifier; @@ -1084,7 +1086,11 @@ class AdminControllerCore extends Controller else $this->context->smarty->assign('confirmations', $this->confirmations); - $this->context->smarty->assign('page', $page); + if ($this->json) + $this->context->smarty->assign('page', Tools::jsonEncode($page)); + else + $this->context->smarty->assign('page', $page); + $this->context->smarty->display($this->layout); }