aboutsummaryrefslogtreecommitdiffstats
path: root/votes.cgi
diff options
context:
space:
mode:
authorlpsolit%gmail.com <>2008-02-03 17:37:20 +0000
committerlpsolit%gmail.com <>2008-02-03 17:37:20 +0000
commit50d2c3150512323bbbbc0801ab79b06a13dd716d (patch)
tree1c8a6aa652d2a7287bd1b5997d9cfde2498784d9 /votes.cgi
parentd4526af8f063d02ae967e0e81de8782e3b2531a1 (diff)
downloadbugs-50d2c3150512323bbbbc0801ab79b06a13dd716d.tar
bugs-50d2c3150512323bbbbc0801ab79b06a13dd716d.tar.gz
bugs-50d2c3150512323bbbbc0801ab79b06a13dd716d.tar.bz2
bugs-50d2c3150512323bbbbc0801ab79b06a13dd716d.tar.xz
bugs-50d2c3150512323bbbbc0801ab79b06a13dd716d.zip
Bug 378797: Ability to turn "My votes" page into a bug list - Patch by GavinS <bugzilla@chimpychompy.org> r/a=LpSolit
Diffstat (limited to 'votes.cgi')
-rwxr-xr-xvotes.cgi6
1 files changed, 6 insertions, 0 deletions
diff --git a/votes.cgi b/votes.cgi
index 9dc728ef8..961db7aa5 100755
--- a/votes.cgi
+++ b/votes.cgi
@@ -144,6 +144,7 @@ sub show_user {
}
}
+ my @all_bug_ids;
my @products;
my $products = $user->get_selectable_products;
# Read the votes data for this user for each product.
@@ -151,6 +152,7 @@ sub show_user {
next unless ($product->votes_per_user > 0);
my @bugs;
+ my @bug_ids;
my $total = 0;
my $onevoteonly = 0;
@@ -178,6 +180,8 @@ sub show_user {
push (@bugs, { id => $id,
summary => $summary,
count => $count });
+ push (@bug_ids, $id);
+ push (@all_bug_ids, $id);
}
$onevoteonly = 1 if (min($product->votes_per_user,
@@ -187,6 +191,7 @@ sub show_user {
if ($#bugs > -1) {
push (@products, { name => $product->name,
bugs => \@bugs,
+ bug_ids => \@bug_ids,
onevoteonly => $onevoteonly,
total => $total,
maxvotes => $product->votes_per_user,
@@ -201,6 +206,7 @@ sub show_user {
$vars->{'voting_user'} = { "login" => $name };
$vars->{'products'} = \@products;
$vars->{'bug_id'} = $bug_id;
+ $vars->{'all_bug_ids'} = \@all_bug_ids;
print $cgi->header();
$template->process("bug/votes/list-for-user.html.tmpl", $vars)