// #PSFV-94 : replace back link with cancel button in the toolbar on all admin controllers
git-svn-id: http://dev.prestashop.com/svn/v1/branches/1.5.x@9876 b9a71923-0436-4b27-9f14-aed3839534dd
This commit is contained in:
@@ -738,10 +738,25 @@ class AdminControllerCore extends Controller
|
||||
// @todo defining default buttons
|
||||
case 'add':
|
||||
case 'edit':
|
||||
// Default save button - action dynamically handled in javascript
|
||||
$this->toolbar_btn['save'] = array(
|
||||
'href' => '#',
|
||||
'desc' => $this->l('Save')
|
||||
);
|
||||
|
||||
case 'view':
|
||||
// Default cancel button - like old back link
|
||||
if (!isset($this->no_back) || $this->no_back == false)
|
||||
{
|
||||
$back = Tools::safeOutput(Tools::getValue('back', ''));
|
||||
if (empty($back))
|
||||
$back = self::$currentIndex.'&token='.$this->token;
|
||||
|
||||
$this->toolbar_btn['cancel'] = array(
|
||||
'href' => $back,
|
||||
'desc' => $this->l('Cancel')
|
||||
);
|
||||
}
|
||||
break;
|
||||
case 'options':
|
||||
break;
|
||||
|
||||
Reference in New Issue
Block a user