johnkeis 6eb24be4e6 Show the build time column
git-svn-id: svn://10.0.0.236/trunk@137286 18797224-902f-48f8-a5cc-f745e15eee43
2003-02-03 03:25:32 +00:00

39 lines
649 B
Perl

package Tinderbox3::BuildTimeColumn;
use strict;
use Date::Format;
sub new {
my $class = shift;
$class = ref($class) || $class;
my $this = {};
bless $this, $class;
my ($p, $dbh) = @_;
return $this;
}
sub column_header {
return "<th>Build Time</th>";
}
sub column_header_2 {
return "<td>Click time to see changes since then</td>";
}
sub cell {
my $this = shift;
my ($rows, $row_num, $column) = @_;
my $class;
if (time2str("%H", $rows->[$row_num][$column]) % 2 == 1) {
$class = "time";
} else {
$class = "time_alt";
}
return "<td class=$class>" . time2str("%D %R", $rows->[$row_num][$column]) . "</td>";
}
1