diff options
author | travis%sedsystems.ca <> | 2005-02-26 02:10:32 +0100 |
---|---|---|
committer | travis%sedsystems.ca <> | 2005-02-26 02:10:32 +0100 |
commit | a0d0ee270e7723f335945ec1ce09dd8efa65ff89 (patch) | |
tree | 18cd4c7aa1d38c25b1668434d7a983d3e12e7a87 /enter_bug.cgi | |
parent | 5d8f3d8e3d5309dbdbb86ab65c7712f370e861fa (diff) | |
download | bugzilla-a0d0ee270e7723f335945ec1ce09dd8efa65ff89.tar.gz bugzilla-a0d0ee270e7723f335945ec1ce09dd8efa65ff89.tar.xz |
Bug 36257 : Have the QA Contact field appear in New Bug submission form
Patch by Shane H. W. Travis <travis@sedsystems.ca> r=LpSolit a=justdave
Diffstat (limited to 'enter_bug.cgi')
-rwxr-xr-x | enter_bug.cgi | 26 |
1 files changed, 17 insertions, 9 deletions
diff --git a/enter_bug.cgi b/enter_bug.cgi index 0dca344ed..f51a1c076 100755 --- a/enter_bug.cgi +++ b/enter_bug.cgi @@ -310,19 +310,24 @@ elsif (1 == @{$::components{$product}}) { } my @components; -SendSQL("SELECT name, description, login_name, realname - FROM components, profiles - WHERE product_id = $product_id - AND initialowner=userid - ORDER BY name"); -while (MoreSQLData()) { - my ($name, $description, $login, $realname) = FetchSQLData(); +my $dbh = Bugzilla->dbh; +my $sth = $dbh->prepare( + q{SELECT name, description, p1.login_name, p2.login_name + FROM components + LEFT JOIN profiles p1 ON components.initialowner = p1.userid + LEFT JOIN profiles p2 ON components.initialqacontact = p2.userid + WHERE product_id = ? + ORDER BY name}); + +$sth->execute($product_id); +while (my ($name, $description, $owner, $qacontact) + = $sth->fetchrow_array()) { push @components, { name => $name, description => $description, - default_login => $login, - default_realname => $realname, + initialowner => $owner, + initialqacontact => $qacontact || '', }; } @@ -342,6 +347,9 @@ $vars->{'assigned_to'} = formvalue('assigned_to'); $vars->{'assigned_to_disabled'} = !UserInGroup('editbugs'); $vars->{'cc_disabled'} = 0; +$vars->{'qa_contact'} = formvalue('qa_contact'); +$vars->{'qa_contact_disabled'} = !UserInGroup('editbugs'); + $vars->{'cloned_bug_id'} = $cloned_bug_id; if ($cloned_bug_id) { |