From: <ri...@us...> - 2008-07-01 09:50:32
|
Revision: 7268 http://bacula.svn.sourceforge.net/bacula/?rev=7268&view=rev Author: ricozz Date: 2008-07-01 02:50:40 -0700 (Tue, 01 Jul 2008) Log Message: ----------- ebl Fix log output to get all messages Modified Paths: -------------- trunk/gui/bweb/lib/Bweb.pm Modified: trunk/gui/bweb/lib/Bweb.pm =================================================================== --- trunk/gui/bweb/lib/Bweb.pm 2008-06-30 21:09:24 UTC (rev 7267) +++ trunk/gui/bweb/lib/Bweb.pm 2008-07-01 09:50:40 UTC (rev 7268) @@ -4492,10 +4492,10 @@ } $query = " -SELECT count(1) AS nbline, JobId AS jobid, - GROUP_CONCAT($logtext $self->{sql}->{CONCAT_SEP}) AS logtxt +SELECT count(1) AS nbline, + GROUP_CONCAT($logtext $self->{sql}->{CONCAT_SEP}) AS logtxt, id FROM ( - SELECT JobId, Time, LogText + SELECT 1 AS id, Time, LogText FROM Log WHERE ( Log.JobId = $arg->{jobid} OR (Log.JobId = 0 @@ -4506,7 +4506,7 @@ LIMIT $arg->{limit} OFFSET $arg->{offset} ) AS temp - GROUP BY JobId + GROUP BY id "; @@ -4918,6 +4918,22 @@ print "<b>$arg->{job}:</b><pre>", sort @ret, "</pre><br>"; } +# permit to verify for higher level backup +# we attempt a Increment, we made a Full, that ok +# TODO: Pool may have change +sub get_higher_level +{ + my ($self, $level) = @_; + if ($level eq 'F') { + return "'F'"; + } elsif ($level eq 'D') { + return "'F', 'D'"; + } elsif ($level eq 'I') { + return "'F', 'D', 'I'"; + } + return "''"; +} + # check jobs against their schedule sub check_job { @@ -4935,6 +4951,7 @@ } my $level = $sched->get_level($s); my ($l) = ($level =~ m/^(.)/); # we keep the first letter + $l = $self->get_higher_level($l); my $evts = $sched->get_event($s); my $end = $sched->{end}; # this backup must have start before the next one @@ -4947,7 +4964,7 @@ AND Job.Name = '$job' AND Job.Type = '$type' AND Job.JobStatus = 'T' - AND Job.Level = '$l' + AND Job.Level IN ($l) " . ($pool?" AND Pool.Name = '$pool' ":'') . " AND Client.Name = '$client' LIMIT 1 This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |