From 6f3e5c8018709ef5a43427c5259e24372eefe7c3 Mon Sep 17 00:00:00 2001 From: "terry%netscape.com" <> Date: Fri, 12 Mar 1999 00:30:51 +0000 Subject: Added 'groups' stuff, where we have different group bits that we can put on a person or on a bug. Some of the group bits control access to bugzilla features. And a person can't access a bug unless he has every group bit set that is also set on the bug. --- bug_form.pl | 32 +++++++++++++++++++++++++++----- 1 file changed, 27 insertions(+), 5 deletions(-) (limited to 'bug_form.pl') diff --git a/bug_form.pl b/bug_form.pl index d56d6b42a..cd2ff0e33 100644 --- a/bug_form.pl +++ b/bug_form.pl @@ -21,6 +21,8 @@ use diagnostics; use strict; +quietly_check_login(); + my $query = " select bug_id, @@ -40,9 +42,11 @@ select target_milestone, qa_contact, status_whiteboard, - date_format(creation_ts,'Y-m-d') + date_format(creation_ts,'Y-m-d'), + groupset from bugs -where bug_id = $::FORM{'id'}"; +where bug_id = $::FORM{'id'} +and bugs.groupset & $::usergroupset = bugs.groupset"; SendSQL($query); my %bug; @@ -53,7 +57,8 @@ if (@row = FetchSQLData()) { "op_sys", "bug_status", "resolution", "priority", "bug_severity", "component", "assigned_to", "reporter", "bug_file_loc", "short_desc", "target_milestone", - "qa_contact", "status_whiteboard", "creation_ts") { + "qa_contact", "status_whiteboard", "creation_ts", + "groupset") { $bug{$field} = shift @row; if (!defined $bug{$field}) { $bug{$field} = ""; @@ -212,11 +217,28 @@ print "
Additional Comments:
-
-
+
"; + + +if ($::usergroupset ne '0') { + SendSQL("select bit, description, (bit & $bug{'groupset'} != 0) from groups where bit & $::usergroupset != 0 and isbuggroup != 0 order by bit"); + while (MoreSQLData()) { + my ($bit, $description, $ison) = (FetchSQLData()); + my $check0 = !$ison ? " SELECTED" : ""; + my $check1 = $ison ? " SELECTED" : ""; + print "
\n"; + } +} + +print "
Leave as $bug{'bug_status'} $bug{'resolution'}
"; + # knum is which knob number we're generating, in javascript terms. my $knum = 1; -- cgit v1.2.3-24-g4f1b