X-Git-Url: https://git.donarmstrong.com/?a=blobdiff_plain;f=cgi%2Fpkgreport.cgi;h=8b733497728f8cd921fdc882dd60d96d4a16e5cb;hb=9e9371254528241edc90f34f8b0d7a08dd1830ca;hp=f4ad4490644ff96c4a16a52a69a4d98b8df9d3ed;hpb=3528bcbf713f93983cce817caf1e9bfc6a40ab36;p=debbugs.git diff --git a/cgi/pkgreport.cgi b/cgi/pkgreport.cgi index f4ad449..8b73349 100755 --- a/cgi/pkgreport.cgi +++ b/cgi/pkgreport.cgi @@ -226,16 +226,15 @@ if (defined $param{maintenc}) { delete $param{maintenc} } - -if (not grep {exists $param{$_}} keys %package_search_keys and exists $param{users}) { - $param{usertag} = [make_list($param{users})]; -} - if (exists $param{pkg}) { $param{package} = $param{pkg}; delete $param{pkg}; } +if (not grep {exists $param{$_}} keys %package_search_keys and exists $param{users}) { + $param{usertag} = [make_list($param{users})]; +} + my %bugusertags; my %ut; my %seen_users; @@ -270,12 +269,6 @@ my $this = munge_url('pkgreport.cgi?', my %indexentry; my %strings = (); -my $dtime = strftime "%a, %e %b %Y %T UTC", gmtime; -my $tail_html = $gHTMLTail; -$tail_html = $gHTMLTail; -$tail_html =~ s/SUBSTITUTE_DTIME/$dtime/; - - my @bugs; # addusers for source and binary packages being searched for @@ -367,6 +360,19 @@ my $title = $gBugs.' '.join(' and ', map {/ or /?"($_)":$_} @title); usertags => \%ut, ); +# shove in bugs which affect this package if there is a package or a +# source given (by default), but no affects options given +if (not exists $param{affects} and not exists $param{noaffects} and + (exists $param{source} or + exists $param{package})) { + push @bugs, get_bugs((map {exists $param{$_}?($_ =~ /^(?:package|source)$/?'affects':$_, + ($_ eq 'source'?'src:'.$param{$_}:$param{$_})):()} + grep {$_ ne 'newest'} + keys %package_search_keys, 'archive'), + usertags => \%ut, + ); +} + if (defined $param{version}) { $title .= " at version $param{version}"; } @@ -431,7 +437,7 @@ if (defined $pseudodesc and defined $pkg and exists $pseudodesc->{$pkg}) { delete $param{dist}; } -# output infomration about the packages +# output information about the packages for my $package (make_list($param{package}||[])) { print generate_package_info(binary => 1, @@ -459,24 +465,6 @@ if (exists $param{submitter}) { print "different addresses.\n"; } -# my $archive_links; -# my @archive_links; -# my %archive_values = (both => 'archived and unarchived', -# 0 => 'not archived', -# 1 => 'archived', -# ); -# while (my ($key,$value) = each %archive_values) { -# next if $key eq lc($param{archive}); -# push @archive_links, qq($value reports ); -# } -# print '
See the '.join (' or ',@archive_links)."
\n"; - print $result; print pkg_javascript() . "\n"; @@ -489,115 +477,10 @@ print option_form(template => 'cgi/pkgreport_options', variables => $form_option_variables, ); -# print "$tail_html"; - +print fill_in_template(template=>'html/html_tail', + hole_var => {'&strftime' => \&POSIX::strftime, + }, + ); print "