aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authordave%intrec.com <>2000-07-20 08:31:10 +0000
committerdave%intrec.com <>2000-07-20 08:31:10 +0000
commit49e0af3d138c3087c91b9c2aa61b21b1edba9d4f (patch)
tree4c1eca1f761e883a1ea9d94aa45c95ab8d44ef65 /editusers.cgi
parentFix for bug 27248 (Bug listings saved with .html extension). Patch (diff)
downloadbugzilla-49e0af3d138c3087c91b9c2aa61b21b1edba9d4f.tar.gz
bugzilla-49e0af3d138c3087c91b9c2aa61b21b1edba9d4f.tar.bz2
bugzilla-49e0af3d138c3087c91b9c2aa61b21b1edba9d4f.zip
Fix for bug 31336 (separate bug groups from access groups in user editor)
Diffstat (limited to 'editusers.cgi')
-rwxr-xr-xeditusers.cgi51
1 files changed, 43 insertions, 8 deletions
diff --git a/editusers.cgi b/editusers.cgi
index e8fdd62c1..7ed8e169d 100755
--- a/editusers.cgi
+++ b/editusers.cgi
@@ -19,7 +19,7 @@
# Rights Reserved.
#
# Contributor(s): Holger Schurig <holgerschurig@nikocity.de>
-#
+# Dave Miller <dave@intrec.com>
#
# Direct any questions on this source code to
#
@@ -139,21 +139,56 @@ sub EmitFormElements ($$$$$$$)
SendSQL("SELECT bit,name,description,bit & $groupset != 0, " .
" bit & $blessgroupset " .
"FROM groups " .
- "WHERE bit & $opblessgroupset != 0 " .
+ "WHERE bit & $opblessgroupset != 0 AND isbuggroup " .
"ORDER BY name");
+ print "</TR><TR><TH VALIGN=TOP ALIGN=RIGHT>Group Access:</TH><TD><TABLE><TR>";
+ my $curgrouptype = 1;
+ if (MoreSQLData()) {
+ if ($editall) {
+ print "<TD COLSPAN=3 ALIGN=LEFT><B>Can turn this bit on for other users</B></TD>\n";
+ print "</TR><TR>\n<TD ALIGN=CENTER><B>|</B></TD>\n";
+ }
+ print "<TD COLSPAN=2 ALIGN=LEFT><B>User is a member of these groups</B></TD>\n";
+ }
while (MoreSQLData()) {
my ($bit,$name,$description,$checked,$blchecked) = FetchSQLData();
print "</TR><TR>\n";
- print " <TH ALIGN=\"right\">", ucfirst($name), ":</TH>\n";
+ if ($editall) {
+ $blchecked = ($blchecked) ? "CHECKED" : "";
+ print "<TD ALIGN=CENTER><INPUT TYPE=CHECKBOX NAME=\"blbit_$name\" $blchecked VALUE=\"$bit\"></TD>";
+ }
$checked = ($checked) ? "CHECKED" : "";
- print " <TD><INPUT TYPE=CHECKBOX NAME=\"bit_$name\" $checked VALUE=\"$bit\"> $description</TD>\n";
+ print "<TD ALIGN=CENTER><INPUT TYPE=CHECKBOX NAME=\"bit_$name\" $checked VALUE=\"$bit\"></TD>";
+ print "<TD><B>" . ucfirst($name) . "</B>: $description</TD>\n";
+ }
+ print "</TR></TABLE></TD>\n";
+
+ SendSQL("SELECT bit,name,description,bit & $groupset != 0, " .
+ " bit & $blessgroupset " .
+ "FROM groups " .
+ "WHERE bit & $opblessgroupset != 0 AND !isbuggroup " .
+ "ORDER BY name");
+ print "</TR><TR><TH VALIGN=TOP ALIGN=RIGHT>Privileges:</TH><TD><TABLE><TR>";
+ my $curgrouptype = 1;
+ if (MoreSQLData()) {
if ($editall) {
- print "</TR><TR>\n";
- print "<TH></TH>";
- $blchecked = ($blchecked) ? "CHECKED" : "";
- print "<TD><INPUT TYPE=CHECKBOX NAME=\"blbit_$name\" $blchecked VALUE=\"$bit\"> Can turn this bit on for other users</TD>\n";
+ print "<TD COLSPAN=3 ALIGN=LEFT><B>Can turn this bit on for other users</B></TD>\n";
+ print "</TR><TR>\n<TD ALIGN=CENTER><B>|</B></TD>\n";
}
+ print "<TD COLSPAN=2 ALIGN=LEFT><B>User has these priveleges</B></TD>\n";
+ }
+ while (MoreSQLData()) {
+ my ($bit,$name,$description,$checked,$blchecked) = FetchSQLData();
+ print "</TR><TR>\n";
+ if ($editall) {
+ $blchecked = ($blchecked) ? "CHECKED" : "";
+ print "<TD ALIGN=CENTER><INPUT TYPE=CHECKBOX NAME=\"blbit_$name\" $blchecked VALUE=\"$bit\"></TD>";
+ }
+ $checked = ($checked) ? "CHECKED" : "";
+ print "<TD ALIGN=CENTER><INPUT TYPE=CHECKBOX NAME=\"bit_$name\" $checked VALUE=\"$bit\"></TD>";
+ print "<TD><B>" . ucfirst($name) . "</B>: $description</TD>\n";
}
+ print "</TR></TABLE></TD>\n";
}