allow to hide all tools
This commit is contained in:
parent
1d8988114b
commit
78e54bb324
|
@ -697,7 +697,8 @@ class lamList {
|
||||||
echo "<button id=\"delButton\" name=\"del\">" . $this->labels['deleteEntry'] . "</button>\n";
|
echo "<button id=\"delButton\" name=\"del\">" . $this->labels['deleteEntry'] . "</button>\n";
|
||||||
}
|
}
|
||||||
$type = new $this->type();
|
$type = new $this->type();
|
||||||
if ($type->supportsFileUpload()) {
|
$toolSettings = $_SESSION['config']->getToolSettings();
|
||||||
|
if ($type->supportsFileUpload() && !(isset($toolSettings['tool_hide_toolFileUpload']) && ($toolSettings['tool_hide_toolFileUpload'] == 'true'))) {
|
||||||
echo ' ';
|
echo ' ';
|
||||||
echo "<button id=\"fileUploadButton\" name=\"fileUpload\">" . _('File upload') . "</button>\n";
|
echo "<button id=\"fileUploadButton\" name=\"fileUpload\">" . _('File upload') . "</button>\n";
|
||||||
}
|
}
|
||||||
|
|
|
@ -123,7 +123,7 @@ class toolFileUpload implements LAMTool {
|
||||||
* @return boolean hideable
|
* @return boolean hideable
|
||||||
*/
|
*/
|
||||||
function isHideable() {
|
function isHideable() {
|
||||||
return false;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -123,7 +123,7 @@ class toolPDFEditor implements LAMTool {
|
||||||
* @return boolean hideable
|
* @return boolean hideable
|
||||||
*/
|
*/
|
||||||
function isHideable() {
|
function isHideable() {
|
||||||
return false;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -123,7 +123,7 @@ class toolProfileEditor implements LAMTool {
|
||||||
* @return boolean hideable
|
* @return boolean hideable
|
||||||
*/
|
*/
|
||||||
function isHideable() {
|
function isHideable() {
|
||||||
return false;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -249,8 +249,11 @@ class lamDHCPList extends lamList {
|
||||||
if (!$createOnly) {
|
if (!$createOnly) {
|
||||||
echo ("<button id=\"delButton\" name=\"del\">" . $this->labels['deleteEntry'] . "</button>\n");
|
echo ("<button id=\"delButton\" name=\"del\">" . $this->labels['deleteEntry'] . "</button>\n");
|
||||||
}
|
}
|
||||||
|
$toolSettings = $_SESSION['config']->getToolSettings();
|
||||||
|
if (!(isset($toolSettings['tool_hide_toolFileUpload']) && ($toolSettings['tool_hide_toolFileUpload'] == 'true'))) {
|
||||||
echo ' ';
|
echo ' ';
|
||||||
echo "<button id=\"fileUploadButton\" name=\"fileUpload\">" . _('File upload') . "</button>\n";
|
echo "<button id=\"fileUploadButton\" name=\"fileUpload\">" . _('File upload') . "</button>\n";
|
||||||
|
}
|
||||||
echo ' ';
|
echo ' ';
|
||||||
echo ("<button id=\"dhcpDefaultsButton\" name=\"dhcpDefaults\">" . $this->labels['dhcpDefaults'] . "</button>\n");
|
echo ("<button id=\"dhcpDefaultsButton\" name=\"dhcpDefaults\">" . $this->labels['dhcpDefaults'] . "</button>\n");
|
||||||
echo " ";
|
echo " ";
|
||||||
|
|
|
@ -131,6 +131,7 @@ foreach ($toSort as $key => $value) {
|
||||||
</li>
|
</li>
|
||||||
<?php
|
<?php
|
||||||
}
|
}
|
||||||
|
if (sizeof($tools) > 0) {
|
||||||
?>
|
?>
|
||||||
<li>
|
<li>
|
||||||
<a href="<?php echo $headerPrefix; ?>tools.php"><img height="16" width="16" alt="tools" src="<?php echo $headerPrefix; ?>../graphics/tools.png"> <?php echo _("Tools") ?></a>
|
<a href="<?php echo $headerPrefix; ?>tools.php"><img height="16" width="16" alt="tools" src="<?php echo $headerPrefix; ?>../graphics/tools.png"> <?php echo _("Tools") ?></a>
|
||||||
|
@ -160,6 +161,7 @@ foreach ($toSort as $key => $value) {
|
||||||
</ul>
|
</ul>
|
||||||
</li>
|
</li>
|
||||||
<?php
|
<?php
|
||||||
|
}
|
||||||
if ($_SESSION['config']->get_Suffix('tree') != "") {
|
if ($_SESSION['config']->get_Suffix('tree') != "") {
|
||||||
?>
|
?>
|
||||||
<li>
|
<li>
|
||||||
|
|
|
@ -41,6 +41,9 @@ include_once('../lib/modules.inc');
|
||||||
// Start session
|
// Start session
|
||||||
startSecureSession();
|
startSecureSession();
|
||||||
|
|
||||||
|
// check if this tool may be run
|
||||||
|
checkIfToolIsActive('toolFileUpload');
|
||||||
|
|
||||||
// die if no write access
|
// die if no write access
|
||||||
if (!checkIfWriteAccessIsAllowed()) die();
|
if (!checkIfWriteAccessIsAllowed()) die();
|
||||||
|
|
||||||
|
|
|
@ -45,6 +45,9 @@ include_once('../lib/pdf.inc');
|
||||||
// Start session
|
// Start session
|
||||||
startSecureSession();
|
startSecureSession();
|
||||||
|
|
||||||
|
// check if this tool may be run
|
||||||
|
checkIfToolIsActive('toolFileUpload');
|
||||||
|
|
||||||
// die if no write access
|
// die if no write access
|
||||||
if (!checkIfWriteAccessIsAllowed()) die();
|
if (!checkIfWriteAccessIsAllowed()) die();
|
||||||
|
|
||||||
|
|
|
@ -43,6 +43,9 @@ include_once('../lib/pdfstruct.inc');
|
||||||
// Start session
|
// Start session
|
||||||
startSecureSession();
|
startSecureSession();
|
||||||
|
|
||||||
|
// check if this tool may be run
|
||||||
|
checkIfToolIsActive('toolFileUpload');
|
||||||
|
|
||||||
// die if no write access
|
// die if no write access
|
||||||
if (!checkIfWriteAccessIsAllowed()) die();
|
if (!checkIfWriteAccessIsAllowed()) die();
|
||||||
|
|
||||||
|
|
|
@ -51,6 +51,8 @@ startSecureSession();
|
||||||
// die if no write access
|
// die if no write access
|
||||||
if (!checkIfWriteAccessIsAllowed()) die();
|
if (!checkIfWriteAccessIsAllowed()) die();
|
||||||
|
|
||||||
|
checkIfToolIsActive('toolPDFEditor');
|
||||||
|
|
||||||
setlanguage();
|
setlanguage();
|
||||||
|
|
||||||
// check if user is logged in, if not go to login
|
// check if user is logged in, if not go to login
|
||||||
|
|
|
@ -47,6 +47,8 @@ startSecureSession();
|
||||||
// die if no write access
|
// die if no write access
|
||||||
if (!checkIfWriteAccessIsAllowed()) die();
|
if (!checkIfWriteAccessIsAllowed()) die();
|
||||||
|
|
||||||
|
checkIfToolIsActive('toolProfileEditor');
|
||||||
|
|
||||||
setlanguage();
|
setlanguage();
|
||||||
|
|
||||||
// check if user is logged in, if not go to login
|
// check if user is logged in, if not go to login
|
||||||
|
|
Loading…
Reference in New Issue