Fix: Note not visible

This commit is contained in:
Laurent Destailleur 2013-01-24 12:16:00 +01:00
parent fa2e9cbd4f
commit 8682d3c928
2 changed files with 7 additions and 5 deletions

View File

@ -522,7 +522,7 @@ else if ($id)
print '<tr><td>'.$langs->trans("Status").'</td><td>'.$object->getLibStatut(4).'</td></tr>';
// Other attributes
$parameters=array('colspan' => ' colspan="3"');
$parameters=array('colspan' => ' colspan="3"', 'showblocbydefault' => 1);
$reshook=$hookmanager->executeHooks('formObjectOptions',$parameters,$object,$action); // Note that $action and $object may have been modified by hook
print "</table><br>";
@ -578,7 +578,8 @@ else if ($id)
}
}
$db->close();
llxFooter();
$db->close();
?>

View File

@ -1,5 +1,6 @@
<?php
/* Copyright (C) 2012 Regis Houssin <regis.houssin@capnetworks.com>
* Copyright (C) 2013 Laurent Destailleur <eldy@users.sourceforge.net>
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
@ -13,11 +14,11 @@
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*
*/
// Hide by default
$hide = (empty($object->extraparams[$blocname]['showhide']) ? true : false);
$hide = true; // Hide by default
if (isset($parameters['showblocbydefault'])) $hide=(empty($parameters['showblocbydefault']) ? true : false);
if (isset($object->extraparams[$blocname]['showhide'])) $hide = (empty($object->extraparams[$blocname]['showhide']) ? true : false);
?>