X-Git-Url: http://git.rot13.org/?p=BackupPC.git;a=blobdiff_plain;f=lib%2FBackupPC%2FCGI%2FBurnMedia.pm;h=cabd5920e2b68f7a2fa676838774d043ea23e606;hp=1a3a53a6efcc169f1f30592eb81494f1b8a80222;hb=1ad5ae30debf935221d2a2bb36289a87cb604a18;hpb=57307aaa251ad94e09d3bf3bf6663d58aa9d7ae7 diff --git a/lib/BackupPC/CGI/BurnMedia.pm b/lib/BackupPC/CGI/BurnMedia.pm index 1a3a53a..cabd592 100644 --- a/lib/BackupPC/CGI/BurnMedia.pm +++ b/lib/BackupPC/CGI/BurnMedia.pm @@ -18,7 +18,7 @@ sub action() { my $dbh = DBI->connect($Conf{SearchDSN}, $Conf{SearchUser}, "", { RaiseError => 1, AutoCommit => 0 } ); BackupPC::CGI::Lib::NewRequest(); - $cont = Dumper(\%In); +# $cont = Dumper(\%In); if (!defined($In{submitBurner})) { $title = eval(q{ ${h1($Lang->{Burn_media})}}); $cont = Dumper(%In); @@ -100,7 +100,26 @@ EOF $cont .= q{ Archived following backups parts: - } . join(", ", @selected_backup_parts) . q{ + } . join(", ", @selected_backup_parts); + + my $sth = $dbh->prepare(qq{ + select + filename, + part_nr, + TIMESTAMP 'epoch' + a.date * INTERVAL '1 second' as date, + size + from archive_backup_parts a + join archive on archive_id = archive.id + where dvd_nr = ? + }); + $sth->execute( $dvd_nr ); + $cont .= ''; + while( my $row = $sth->fetchrow_arrayref ) { + $cont .= ''; + } + $cont .= '
' . join('', @$row) . '
'; + + $cont .= q{
with total size of } . unit($total_size) . q{ @@ -110,6 +129,8 @@ EOF } . $In{'note'} . q{ }; + + } }