Add support for Ingrasys iPoMan 1201 + minor fixes

git-svn-id: http://www.observium.org/svn/observer/trunk@1726 61d68cd4-352d-0410-923a-c4978735b2b8
This commit is contained in:
Tom Laermans
2010-11-19 22:46:24 +00:00
parent 349cd58779
commit f5c7d989f6
16 changed files with 4813 additions and 6 deletions

View File

@@ -7,7 +7,7 @@ if($total = mysql_result(mysql_query("SELECT count(sensor_id) from sensors WHERE
echo("<div style='background-color: #eeeeee; margin: 5px; padding: 5px;'>");
echo("<p style='padding: 0px 5px 5px;' class=sectionhead><img align='absmiddle' src='".$config['base_url']."/images/icons/current.png'> Current</p>");
$i = '1';
$currents = mysql_query("SELECT * FROM sensors WHERE sensor_class='current' AND device_id = '" . $device['device_id'] . "'");
$currents = mysql_query("SELECT * FROM sensors WHERE sensor_class='current' AND device_id = '" . $device['device_id'] . "' ORDER BY sensor_index");
echo("<table width=100% valign=top>");
while($current = mysql_fetch_array($currents)) {
if(is_integer($i/2)) { $row_colour = $list_colour_a; } else { $row_colour = $list_colour_b; }

View File

@@ -24,7 +24,7 @@ if($total = mysql_result(mysql_query("SELECT count(sensor_id) from sensors WHERE
$humidity_year = "graph.php?id=" . $humidity['sensor_id'] . "&type=".$graph_type."&from=$year&to=$now&width=300&height=100";
$humidity_minigraph = "<img src='graph.php?id=" . $humidity['sensor_id'] . "&type=".$graph_type."&from=$day&to=$now&width=80&height=20&bg=$graph_colour' align='absmiddle'>";
$humidity_link = "<a href='device/".$device['device_id']."/health/humiditys/' onmouseover=\"return ";
$humidity_link = "<a href='device/".$device['device_id']."/health/humidity/' onmouseover=\"return ";
$humidity_link .= "overlib('<div class=list-large>".$device['hostname']." - ".$humidity['sensor_descr'];
$humidity_link .= "</div><div style=\'width: 750px\'><img src=\'$humidity_day\'><img src=\'$humidity_week\'><img src=\'$humidity_month\'><img src=\'$humidity_year\'></div>', RIGHT".$config['overlib_defaults'].");\" onmouseout=\"return nd();\" >";
@@ -34,7 +34,7 @@ if($total = mysql_result(mysql_query("SELECT count(sensor_id) from sensors WHERE
$humidity['sensor_descr'] = truncate($humidity['sensor_descr'], 25, '');
echo("<tr bgcolor='$row_colour'><td class=tablehead><strong>$humidity_link_a</strong></td><td width=80 align=right class=tablehead>$humidity_link_b<td width=80 align=right class=tablehead>$humidity_link_c</td></tr>");
if($i == $rows) { echo("</table></td><td valign=top><table width=100% cellspacing=0 cellpadding=2>"); }
# if($i == $rows) { echo("</table></td><td valign=top><table width=100% cellspacing=0 cellpadding=2>"); }
$i++;
}
echo("</table>");

View File

@@ -7,7 +7,7 @@ if($total = mysql_result(mysql_query("SELECT count(sensor_id) from sensors WHERE
echo("<div style='background-color: #eeeeee; margin: 5px; padding: 5px;'>");
echo("<p style='padding: 0px 5px 5px;' class=sectionhead><img align='absmiddle' src='".$config['base_url']."/images/icons/voltages.png'> Voltages</p>");
$i = '1';
$volts = mysql_query("SELECT * FROM sensors WHERE sensor_class='voltage' AND device_id = '" . $device['device_id'] . "'");
$volts = mysql_query("SELECT * FROM sensors WHERE sensor_class='voltage' AND device_id = '" . $device['device_id'] . "' ORDER BY sensor_index");
echo("<table width=100% valign=top>");
while($volt = mysql_fetch_array($volts)) {
if(is_integer($i/2)) { $row_colour = $list_colour_a; } else { $row_colour = $list_colour_b; }