diff options
author | Byron Jones <bjones@mozilla.com> | 2013-01-28 18:55:09 +0100 |
---|---|---|
committer | Byron Jones <bjones@mozilla.com> | 2013-01-28 18:55:09 +0100 |
commit | cae57f72c1bc2735149a8256c91852d59b741462 (patch) | |
tree | dd3c999ff6179f694f8a724a34e2e043ece678ab /extensions/BMO/Extension.pm | |
parent | efb798dc33f46526974a85ac725b520984bc2c12 (diff) | |
download | bugzilla-cae57f72c1bc2735149a8256c91852d59b741462.tar.gz bugzilla-cae57f72c1bc2735149a8256c91852d59b741462.tar.xz |
Bug 833369: Create a Documentation Request bugzilla form
Diffstat (limited to 'extensions/BMO/Extension.pm')
-rw-r--r-- | extensions/BMO/Extension.pm | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/extensions/BMO/Extension.pm b/extensions/BMO/Extension.pm index 84d04b0f8..186a83f73 100644 --- a/extensions/BMO/Extension.pm +++ b/extensions/BMO/Extension.pm @@ -28,6 +28,7 @@ use base qw(Bugzilla::Extension); use Bugzilla::Field; use Bugzilla::Constants; use Bugzilla::Status; +use Bugzilla::Product; use Bugzilla::User; use Bugzilla::User::Setting; use Bugzilla::Util qw(html_quote trick_taint trim datetime_from detaint_natural); @@ -123,18 +124,24 @@ sub template_before_process { $vars->{'columns_sortkey'} = \%columns_sortkey; } - elsif ($file =~ /^bug\/create\/create[\.-]/) { + elsif ($file =~ /^bug\/create\/create[\.-](.*)/) { + my $format = $1; if (!$vars->{'cloned_bug_id'}) { # Allow status whiteboard values to be bookmarked $vars->{'status_whiteboard'} = Bugzilla->cgi->param('status_whiteboard') || ""; } - + # Purpose: for pretty product chooser $vars->{'format'} = Bugzilla->cgi->param('format'); # Data needed for "this is a security bug" checkbox $vars->{'sec_groups'} = \%product_sec_groups; + + if ($format eq 'doc.html.tmpl') { + my $versions = Bugzilla::Product->new({ name => 'Core' })->versions; + $vars->{'versions'} = [ reverse @$versions ]; + } } |