From 831030614c615d190a2a2c8b57d6c3b175628f56 Mon Sep 17 00:00:00 2001 From: "justdave%syndicomm.com" <> Date: Thu, 9 Aug 2001 13:12:18 +0000 Subject: Re-fix for bug 55161 - if data is partial in activity table, prepend a ? to indicate that we don't know for sure what got dropped. Patch by Jake Steenhagen r= justdave@syndicomm.com --- CGI.pl | 41 +++++++++++++++++++++++++++++------------ 1 file changed, 29 insertions(+), 12 deletions(-) (limited to 'CGI.pl') diff --git a/CGI.pl b/CGI.pl index 425956370..2f1a189b3 100644 --- a/CGI.pl +++ b/CGI.pl @@ -1147,27 +1147,44 @@ sub DumpBugActivity { SendSQL($query); - print "\n"; - print "\n"; - print " \n"; - print "\n"; + # Instead of outright printing this, we are going to store it in a $html + # variable and print it and the end. This is so we can explain ? (if nesc.) + # at the top of the activity table rather than the botom. + my $html = ""; + $html .= "
WhoWhatRemovedAddedWhen
\n"; + $html .= "\n"; + $html .= " \n"; + $html .= "\n"; my @row; + my $incomplete_data = 0; while (@row = FetchSQLData()) { my ($field,$when,$removed,$added,$who) = (@row); $removed = html_quote($removed); $added = html_quote($added); $removed = " " if $removed eq ""; $added = " " if $added eq ""; - print "\n"; - print "\n"; - print "\n"; - print "\n"; - print "\n"; - print "\n"; - print "\n"; + if ($added =~ /^\?/ || $removed =~ /^\?/) { + $incomplete_data = 1; + } + $html .= "\n"; + $html .= "\n"; + $html .= "\n"; + $html .= "\n"; + $html .= "\n"; + $html .= "\n"; + $html .= "\n"; + } + $html .= "
WhoWhatRemovedAddedWhen
$who$field$removed$added$when
$who$field$removed$added$when
\n"; + if ($incomplete_data) { + print "There was a bug in older versions of Bugzilla which caused activity data \n"; + print "to be lost if there was a large number of cc's or dependencies. That \n"; + print "has been fixed, however, there was some data already lost on this bug \n"; + print "that could not be regenerated. The changes that the script could not \n"; + print "reliably determine are prefixed by '?'\n"; + print "

\n"; } - print "\n"; + print $html; } -- cgit v1.2.3-24-g4f1b