Changeset 286
- Timestamp:
- Jul 16, 2018, 7:36:34 PM (6 years ago)
- Location:
- trunk/nagios-velvice
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/nagios-velvice/velvice.cgi
r285 r286 15 15 use strict; 16 16 use warnings; 17 use version; our $VERSION = version->declare('0.8. 4');17 use version; our $VERSION = version->declare('0.8.5'); 18 18 19 19 use CGI; … … 179 179 my $color = $status eq 'CRITICAL' ? '#F88888' : '#FFFF00'; 180 180 $color = alertcolor($color, $downtime); 181 $htmlpage .= " <tr style='background:$color;'>\n"; 181 my $stylecolor = "style='background:$color;'"; 182 $htmlpage .= " <tr>\n"; 182 183 if ($hostname ne $current_host) { 183 184 $current_host = $hostname; 184 $htmlpage .= " <td rowspan='$hostcount{$hostname}' style='vertical-align:middle;'>"185 $htmlpage .= " <td rowspan='$hostcount{$hostname}' $stylecolor>" 185 186 . "<a href=\"$cgi_script_name?check=" . uri_encode($hostname) . '">↯</a></td>' . "\n"; 186 $htmlpage .= " <td class='hoop' rowspan='$hostcount{$hostname}' style='vertical-align:middle;'>"187 $htmlpage .= " <td class='hoop' rowspan='$hostcount{$hostname}' $stylecolor>" 187 188 . "<a href=\"$config->{'nagios-server'}{'status-cgi'}?host=" . uri_encode($hostname) . "\">$hostname</a></td>\n"; 188 189 } … … 194 195 $bold++ if $service =~ m/$act_regex/ and $config->{'remote-action'}{$act_name}{'style'} eq 'bold'; 195 196 } 196 $htmlpage .= $bold ? ' <td class="hoop bold">' : ' <td class="hoop">';197 $htmlpage .= $bold ? " <td class='hoop bold' $stylecolor>" : " <td class='hoop' $stylecolor>"; 197 198 $htmlpage .= "$service</td>\n"; 198 199 199 $htmlpage .= " <td class='hoop'>$status</td>\n"; 200 $htmlpage .= " <td style='max-width:60%;'><small>$output"; 200 $htmlpage .= " <td class='hoop' $stylecolor>$status</td>\n"; 201 $htmlpage .= " <td class='comment' $stylecolor>$output</td>\n"; 202 $htmlpage .= " <td class='days"; 201 203 202 204 if (($cgi_check =~ m/all/i) … … 213 215 my $future = $now + 20 + int(rand($interval - 20)); # 5 * 60 = 300 214 216 215 $htmlpage .= " -- <b>CHECK</b> [$now/" . ($future - $now) . "]"; 217 $htmlpage .= ' checking'; # add class checking 218 #$htmlpage .= " -- <b>CHECK</b> [$now/" . ($future - $now) . "]"; 216 219 printf $nagios_cmd "[%lu] SCHEDULE_FORCED_SVC_CHECK;%s;%s;%lu\n", $now, $hostname, $service, $now; 217 220 # delay future command … … 236 239 } 237 240 238 $htmlpage .= "</small></td>\n"; 239 $htmlpage .= " <td style='text-align:right;'>$downtime days</td>\n"; 241 $htmlpage .= "' $stylecolor>$downtime days</td>\n"; 240 242 $htmlpage .= " </tr>\n"; 241 243 } -
trunk/nagios-velvice/velvice.css
r284 r286 76 76 td { 77 77 border: 0px; 78 vertical-align: middle; 78 79 } 79 80 … … 84 85 td.hoop { 85 86 border: 1px solid #777; 87 } 88 89 td.comment { 90 max-width: 60%; 91 font-size: small; 92 } 93 94 td.days { 95 text-align: right; 96 } 97 98 td.checking:after { 99 background-color: red; 100 color: white; 101 content: "\21B5"; 102 padding: 0ex 0.8ex 0ex 0.8ex; 103 border-radius: 0ex 0px 0px 2ex; 86 104 } 87 105
Note: See TracChangeset
for help on using the changeset viewer.