X-Git-Url: http://git.rot13.org/?p=BackupPC.git;a=blobdiff_plain;f=lib%2FBackupPC%2FCGI%2FDirHistory.pm;h=30162f052079fffdfa8a499bb3c44fb7780dd2a5;hp=a1b2d2d1ff4b774cd15c02e403f5669998bd851a;hb=e951f787a66c5bd9e9955c3f657a5b44289c0fe1;hpb=4ccad54a1f16abeffa0bf9a96df117d378eba9c1
diff --git a/lib/BackupPC/CGI/DirHistory.pm b/lib/BackupPC/CGI/DirHistory.pm
index a1b2d2d..30162f0 100644
--- a/lib/BackupPC/CGI/DirHistory.pm
+++ b/lib/BackupPC/CGI/DirHistory.pm
@@ -28,7 +28,7 @@
#
#========================================================================
#
-# Version 2.1.0_CVS, released 3 Jul 2003.
+# Version 2.1.0, released 20 Jun 2004.
#
# See http://backuppc.sourceforge.net.
#
@@ -71,7 +71,8 @@ sub action
ErrorExit($Lang->{Nice_try__but_you_can_t_put});
}
- for ( $i = 0 ; $i < @Backups ; $i++ ) {
+ my @backupList = $view->backupList($share, $dir);
+ foreach $i ( @backupList ) {
my $backupTime = timeStamp2($Backups[$i]{startTime});
my $num = $Backups[$i]{num};
$backupNumStr .= "
$fDisp | ";
+ my($colSpan, $url, $inode, $type);
+ my $tdClass = ' class="histView"';
+ foreach $i ( @backupList ) {
my($path);
if ( $colSpan > 0 ) {
#
@@ -109,16 +111,16 @@ sub action
$colSpan++;
next;
}
- $fileStr .= ""
+ $fileStr .= " | "
. "$url | ";
$colSpan = 0;
- $tdColor = "";
+ $tdClass = ' class="histView"';
}
if ( !defined($hist->{$f}[$i]) ) {
$colSpan = 1;
$url = " ";
$inode = -3; # special value for missing
- $tdColor = ' bgcolor="#ffffaa"';
+ $tdClass = ' class="histViewMis"';
next;
}
if ( $dir eq "" ) {
@@ -154,7 +156,7 @@ EOF
$colSpan = 1;
}
if ( $colSpan > 0 ) {
- $fileStr .= "$url | ";
+ $fileStr .= "$url | ";
$colSpan = 0;
}
$fileStr .= "\n";
@@ -164,11 +166,8 @@ EOF
$dirDisplay =~ s{//+}{/}g;
$dirDisplay =~ s{/+$}{}g;
$dirDisplay = "/" if ( $dirDisplay eq "" );
-
- Header(eval("qq{$Lang->{DirHistory_backup_for__host}}"));
-
- print (eval("qq{$Lang->{DirHistory_for__host}}"));
-
+ my $content = eval("qq{$Lang->{DirHistory_for__host}}");
+ Header(eval("qq{$Lang->{DirHistory_backup_for__host}}"), $content);
Trailer();
}