diff options
author | David Lawrence <dkl@mozilla.com> | 2015-10-14 17:53:48 +0200 |
---|---|---|
committer | David Lawrence <dkl@mozilla.com> | 2015-10-14 17:53:56 +0200 |
commit | 0e11b4a741c9104db967a2c51fa77b071cb087f5 (patch) | |
tree | 27605728dab566604a46ef740e87d487dda79567 /extensions/BMO | |
parent | 9c792196e7f940dacda41424ed25a02bb4c0b633 (diff) | |
download | bugzilla-0e11b4a741c9104db967a2c51fa77b071cb087f5.tar.gz bugzilla-0e11b4a741c9104db967a2c51fa77b071cb087f5.tar.xz |
Bug 1195952 - Please add the following choices to the CAB review drop down area of bugzilla
Diffstat (limited to 'extensions/BMO')
-rw-r--r-- | extensions/BMO/Extension.pm | 12 | ||||
-rw-r--r-- | extensions/BMO/lib/Data.pm | 5 |
2 files changed, 16 insertions, 1 deletions
diff --git a/extensions/BMO/Extension.pm b/extensions/BMO/Extension.pm index 6938eb790..16caecc9a 100644 --- a/extensions/BMO/Extension.pm +++ b/extensions/BMO/Extension.pm @@ -549,8 +549,18 @@ sub bug_check_can_change_field { my $user = Bugzilla->user; if ($field =~ /^cf/ && !@$priv_results && $new_value ne '---') { + # Cannot use the standard %cf_setter mapping as we want anyone + # to be able to set ?, just not the other values. + if ($field eq 'cf_cab_review') { + if ($new_value ne '1' + && $new_value ne '?' + && !$user->in_group('infra', $bug->product_id)) + { + push (@$priv_results, PRIVILEGES_REQUIRED_EMPOWERED); + } + } # "other" custom field setters restrictions - if (exists $cf_setters->{$field}) { + elsif (exists $cf_setters->{$field}) { my $in_group = 0; foreach my $group (@{$cf_setters->{$field}}) { if ($user->in_group($group, $bug->product_id)) { diff --git a/extensions/BMO/lib/Data.pm b/extensions/BMO/lib/Data.pm index ab9c15353..d5a87b50a 100644 --- a/extensions/BMO/lib/Data.pm +++ b/extensions/BMO/lib/Data.pm @@ -144,6 +144,11 @@ tie(%$cf_visible_in_products, "Tie::IxHash", "Firefox" => [], "Toolkit" => [], }, + qr/^cf_cab_review$/ => { + "Developer Services" => [], + "Infrastructure & Operations Graveyard" => [], + "Infrastructure & Operations" => [], + } ); # Who to CC on particular bugmails when certain groups are added or removed. |