git-svn-id: http://www.observium.org/svn/observer/trunk@125 61d68cd4-352d-0410-923a-c4978735b2b8
This commit is contained in:
Adam Amstrong
2008-03-09 17:39:14 +00:00
parent b8f38d6d24
commit 75f4bac3a2
11 changed files with 70 additions and 11 deletions
+3
View File
@@ -10,3 +10,6 @@ RewriteCond %{REQUEST_URI} !^(.*)\.png$
RewriteRule ^([a-z]+)$ ?page=$1
RewriteRule ^bills/([0-9]+) ?page=bills&bill=$1
RewriteRule ^device/([0-9]+) ?page=device&id=$1
+4 -1
View File
@@ -13,13 +13,16 @@ A.green:visited, A.green, .green {color: #008C00;}
A.blue:visited, A.blue, .blue {color: #0000ff;}
A.orange:visited, a.orange, .orange {color: #FF7400;}
.pinkbg { background-color: #ffbbbb; }
.redbg { background-color: #ff8585; }
.bluebg { background-color: #aaaaff; }
.greenbg { background-color: #aaffaa; }
.greybg { background-color: #dddddd; }
.selector {
width:275px;
}
.page-h2 {
font-size: 14px;
font-weight: bold;
+5 -1
View File
@@ -10,6 +10,11 @@
include("../includes/functions.php");
include("includes/authenticate.inc");
if($_GET['params']) {
list($_GET['host'], $_GET['if'], $_GET['from'], $_GET['to'], $_GET['width'], $_GET['height'], $_GET['title'], $_GET['vertical'], $_GET['type'], $_GET['interfaces']) = explode("||", mcrypt_ecb(MCRYPT_DES, $key_value, $_GET['params'], MCRYPT_DECRYPT));
}
if($_GET['host']) {
$device_id = $_GET['host'];
} elseif($_GET['device']) {
@@ -28,7 +33,6 @@
$height = $_GET['height'];
$title = $_GET['title'];
$vertical = $_GET['vertical'];
$type = $_GET['type'];
$graphfile = strgen() . ".png";
+3
View File
@@ -108,6 +108,9 @@ if($_SESSION['userlevel'] >= '10') {
if($_SESSION['userlevel'] >= '5') {
echo("<li><hr width=140 /></li>");
if($show_if_customers) { echo("<li><a href='?page=customers'><img src='/images/16/group_link.png' border=0 align=absmiddle> Customers</a></li>"); $ifbreak = 1;}
if($show_if_bills) { echo("<li><a href='?page=bills'><img src='/images/16/money_pound.png' border=0 align=absmiddle> Traffic Bills</a></li>"); $ifbreak = 1;}
if($show_if_l2tp) { echo("<li><a href='?page=iftype&type=l2tp'><img src='/images/16/user.png'border=0 align=absmiddle> L2TP</a></li>"); $ifbreak = 1; }
if($show_if_transit) { echo("<li><a href='?page=iftype&type=transit'><img src='/images/16/world_link.png' border=0 align=absmiddle> Transit</a></li>"); $ifbreak = 1; }
+1
View File
@@ -28,6 +28,7 @@ if($_GET[debug]) {
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en">
<head>
<title><?php echo("$page_title"); ?></title>
<base href="<?php echo("$base_url"); ?>" />
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<!-- <meta http-equiv="refresh" content="300"> -->
<link href="<?php echo($stylesheet); ?>" rel="stylesheet" type="text/css">
+3 -3
View File
@@ -23,7 +23,7 @@ while($device = mysql_fetch_array($sql)){
}
$sql = mysql_query("SELECT * FROM `devices` WHERE `status` = '0'");
$sql = mysql_query("SELECT * FROM `devices` WHERE `status` = '0' AND `ignore` = '0'");
while($device = mysql_fetch_array($sql)){
unset($already);
$i = 0;
@@ -37,7 +37,7 @@ while($device = mysql_fetch_array($sql)){
if(!$already) { $nodes[] = $device['device_id']; }
}
$sql = mysql_query("SELECT * FROM `interfaces` AS I, `devices` AS D WHERE I.device_id = D.device_id AND ifOperStatus = 'down' AND ifAdminStatus = 'up'");
$sql = mysql_query("SELECT * FROM `interfaces` AS I, `devices` AS D WHERE I.device_id = D.device_id AND ifOperStatus = 'down' AND ifAdminStatus = 'up' AND D.ignore = '0' AND I.ignore = '0'");
while($device = mysql_fetch_array($sql)){
unset($already);
$i = 0;
@@ -51,7 +51,7 @@ while($device = mysql_fetch_array($sql)){
if(!$already) { $nodes[] = $device['device_id']; }
}
$sql = mysql_query("SELECT D.device_id FROM `services` AS S, `devices` AS D WHERE S.service_host = D.device_id AND service_status = 'down'");
$sql = mysql_query("SELECT D.device_id FROM `services` AS S, `devices` AS D WHERE S.service_host = D.device_id AND service_status = 'down' AND D.ignore = '0' AND S.service_ignore = '0'");
while($device = mysql_fetch_array($sql)){
unset($already);
$i = 0;
+1 -1
View File
@@ -34,7 +34,7 @@ echo("<table cellpadding=0 cellspacing=0><tr><td>
<table width='200' border='0'>
<tr>
<td width='300'><div align='right'>Description</div></td>
<td colspan='3'><textarea name='descr' cols='50'>$descr</textarea></td>
<td colspan='3'><input name='descr' width='50'>$descr</textarea></td>
</tr>
<tr>
<td>
+1 -1
View File
@@ -6,7 +6,7 @@
<tr>
<td><div align='right'><img src='/images/password.png' width='128' height='128'></div></td>
<td>
<form action='index.php' method=post>
<form action='". $_SERVER['REQUEST_URI'] ."' method=post>
<h3>Please log in:</h3>
<div style='height: 0px;'></div>