CustomActions : Added disableOnSuccessMsg parameter

This commit is contained in:
Benjamin Renard 2011-05-20 18:11:42 +02:00
parent 62bb6c55a1
commit 5d911be334

View file

@ -42,12 +42,14 @@ if(LSsession :: startLSsession()) {
$objectname=$object -> getDisplayName();
$GLOBALS['Smarty'] -> assign('pagetitle',$title.' : '.$objectname);
if ($config['function']($object)) {
if ($config['disableOnSuccessMsg']!=true) {
if ($config['onSuccessMsgFormat']) {
LSsession :: addInfo(getFData($config['onSuccessMsgFormat'],$objectname));
}
else {
LSsession :: addInfo(getFData(_('The custom action %{customAction} have been successfully execute on %{objectname}.'),array('objectname' => $objectname,'customAction' => $_GET['customAction'])));
}
}
LSsession :: redirect('view.php?LSobject='.$_GET['LSobject'].'&refresh');
}
else {