Commit 740e0366 authored by bugreport%peshkin.net's avatar bugreport%peshkin.net

Bug 315332 fix several bugs in process_bug.cgi when 'strict_isolation' is on

Patch by Joel Peshkin <bugreport@peshkin.net> r=lpsolit, a=justdave
parent da94d077
......@@ -1299,17 +1299,6 @@ sub ValidateDependencies {
return %deps;
}
#Verify if the new assignee belongs to the group of
#the product that the bug(s) is in.
sub can_add_user_to_bug {
my ($prod_id, $id, $uid) = @_;
my $user = new Bugzilla::User($uid);
if (!$user->can_edit_product($prod_id)) {
ThrowUserError("invalid_user_group", { 'user' =>
$user->login, bug_id => $id });
}
}
sub AUTOLOAD {
use vars qw($AUTOLOAD);
my $attr = $AUTOLOAD;
......
......@@ -670,8 +670,19 @@
[% ELSIF error == "invalid_user_group" %]
[% title = "Invalid User Group" %]
User '[% user FILTER html %]' is not able to edit the
[% terms.bug %] '[% bug_id FILTER html %]'.
[% IF users.size > 1 %] Users [% ELSE %] User [% END %]
'[% users.join(', ') FILTER html %]'
[% IF users.size > 1 %] are [% ELSE %] is [% END %]
not able to edit the
[% IF product %]
'[% product FILTER html %]'
[% END %]
[%+ field_descs.product FILTER html %]
[% IF bug_id %]
for [% terms.bug %] '[% bug_id FILTER html %]'.
[% ELSE %]
for at least one [% terms.bug %] being changed.
[% END %]
[% ELSIF error == "invalid_username" %]
[% title = "Invalid Username" %]
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment