html/includes/graphs/device/sla.inc.php =================================================================== --- html/includes/graphs/device/sla.inc.php (revision 1) +++ html/includes/graphs/device/sla.inc.php (working copy) @@ -23,8 +23,7 @@ $unit = 'ms'; $rrd_options .= " -l 0 -E "; -$rrd_options .= " COMMENT:'".str_pad($unit_long,$descr_len)." Cur Min Max\\n'"; - +$rrd_options .= " COMMENT:".$unit_long."\\l"; #$descr = ""; $descr = $sla['sla_nr']." "; if ($sla['tag']) @@ -33,13 +32,7 @@ $descr .= " (Owner: ". $sla['owner'] .")"; $rrd_file = get_rrd_path($device, "sla-" . $sla['sla_nr'] . ".rrd"); -$rrd_options .= " DEF:rtt=$rrd_file:rtt:AVERAGE "; -$rrd_options .= " VDEF:avg=rtt,AVERAGE "; -$rrd_options .= " LINE1:avg#CCCCFF:'".str_pad('Average',$descr_len-3)."':dashes"; -$rrd_options .= " GPRINT:rtt:AVERAGE:%4.1lf".$unit."\\\l "; -$rrd_options .= " LINE1:rtt#CC0000:'" . rrdtool_escape($descr) . "'"; -$rrd_options .= " GPRINT:rtt:LAST:%4.1lf".$unit." "; -$rrd_options .= " GPRINT:rtt:MIN:%4.1lf".$unit." "; -$rrd_options .= " GPRINT:rtt:MAX:%4.1lf".$unit."\\\l "; +//DRAW GRAPH BASED ON THE SLA TYPE +include($config['html_dir']."/includes/graphs/device/sla_".$sla['rtt_type'].".inc.php"); -?> +//EOF