mirror of
https://github.com/librenms/librenms.git
synced 2024-10-07 16:52:45 +00:00
change show_printers to enable_printers, add printer tab (still empty) to printer devices and fix syntax error
git-svn-id: http://www.observium.org/svn/observer/trunk@1015 61d68cd4-352d-0410-923a-c4978735b2b8
This commit is contained in:
@ -80,7 +80,6 @@ $config['int_l2tp'] = 0; # Enable L2TP Port Types
|
||||
|
||||
$config['show_locations'] = 1; # Enable Locations on menu
|
||||
$config['show_services'] = 1; # Enable Services on menu
|
||||
$config['show_printers'] = 0; # Enable Printers Device Type on menu
|
||||
|
||||
$config['ports_page_default'] = "details/";
|
||||
# Default devices ports page display type. "details/", "graphs/bits/", etc
|
||||
@ -95,6 +94,7 @@ $config['enable_etherlike'] = 1; # Enable Etherlike
|
||||
$config['enable_pseudowires'] = 1; # Enable Pseudowires
|
||||
$config['enable_ports_junoseatmvp'] = 0; # Enable JunOSe ATM VC Discovery/Poller
|
||||
$config['enable_ports_etherlike'] = 0; # Enable Polling EtherLike-MIB (doubles interface processing time)
|
||||
$config['enable_printers'] = 0; # Enable Printer support
|
||||
|
||||
#$config['rancid_configs'] = '/var/lib/rancid/network/configs/';
|
||||
$config['rancid_ignorecomments'] = 0; # Ignore lines starting with #
|
||||
|
@ -51,7 +51,7 @@
|
||||
<li><a href="devices/network/"><img src="images/16/arrow_switch.png" border="0" align="absmiddle" /> Network</a></li>
|
||||
<li><a href="devices/firewall/"><img src="images/16/shield.png" border="0" align="absmiddle" /> Firewalls</a></li>
|
||||
<?php
|
||||
if (isset($config['show_printers']) && $config['show_printers'])
|
||||
if (isset($config['enable_printers']) && $config['enable_printers'])
|
||||
{
|
||||
?>
|
||||
<li><a href="devices/printer/"><img src="images/16/printer.png" border="0" align="absmiddle" /> Printers</a></li>
|
||||
|
@ -157,6 +157,15 @@ if(mysql_result(mysql_query("select count(service_id) from services WHERE device
|
||||
');
|
||||
}
|
||||
|
||||
if(@mysql_result(mysql_query("select count(toner_id) from toner WHERE device_id = '" . $device['device_id'] . "'"), 0) > '0') {
|
||||
echo('<li class="' . $select['toner'] . '">
|
||||
<a href="'.$config['base_url'].'/device/' . $device['device_id'] . '/toner/">
|
||||
<img src="images/16/color_wheel.png" align="absmiddle" border="0" /> Toner
|
||||
</a>
|
||||
</li>');
|
||||
}
|
||||
|
||||
|
||||
echo('<li class="' . $select['events'] . '">
|
||||
<a href="'.$config['base_url']. "/device/" . $device['device_id'] . '/events/">
|
||||
<img src="images/16/report_magnify.png" align="absmiddle" border="0" /> Events
|
||||
|
@ -1,6 +1,6 @@
|
||||
<?php
|
||||
|
||||
if ($config['show_printers'])
|
||||
if ($config['enable_printers'])
|
||||
{
|
||||
|
||||
$id = $device['device_id'];
|
||||
@ -62,5 +62,5 @@ if ($query = mysql_query($sql))
|
||||
|
||||
unset($toner_exists); echo("\n");
|
||||
|
||||
} # if ($config['show_printers'])
|
||||
} # if ($config['enable_printers'])
|
||||
?>
|
||||
|
@ -164,7 +164,7 @@ while ($device = mysql_fetch_array($device_query)) {
|
||||
include("includes/polling/ports.inc.php");
|
||||
include("includes/polling/cisco-mac-accounting.inc.php");
|
||||
include("includes/polling/bgpPeer.inc.php");
|
||||
include("includes/polling/toner.inc.php")
|
||||
include("includes/polling/toner.inc.php");
|
||||
|
||||
unset( $update ) ;
|
||||
unset( $seperator) ;
|
||||
|
Reference in New Issue
Block a user