summaryrefslogtreecommitdiffstats
path: root/process_bug.cgi
diff options
context:
space:
mode:
authorbugreport%peshkin.net <>2002-10-31 23:45:19 +0100
committerbugreport%peshkin.net <>2002-10-31 23:45:19 +0100
commitcf6262d55a4d22906625cf659d94736515393122 (patch)
tree47d56bcd86a623f9fa447b7c5ac9bac6042d59fc /process_bug.cgi
parent4fc0668c40ac6e71b5418d6cbc2127eeb4e97c91 (diff)
downloadbugzilla-cf6262d55a4d22906625cf659d94736515393122.tar.gz
bugzilla-cf6262d55a4d22906625cf659d94736515393122.tar.xz
Bug 95430 Reopening en masse fails.
Patch by jeff.hedlund r=justdave, joel
Diffstat (limited to 'process_bug.cgi')
-rwxr-xr-xprocess_bug.cgi13
1 files changed, 8 insertions, 5 deletions
diff --git a/process_bug.cgi b/process_bug.cgi
index bf0edc09c..0450b7ce9 100755
--- a/process_bug.cgi
+++ b/process_bug.cgi
@@ -898,12 +898,8 @@ SWITCH: for ($::FORM{'knob'}) {
last SWITCH;
};
/^reopen$/ && CheckonComment( "reopen" ) && do {
- SendSQL("SELECT resolution FROM bugs WHERE bug_id = $::FORM{'id'}");
ChangeStatus('REOPENED');
ChangeResolution('');
- if (FetchOneColumn() eq 'DUPLICATE') {
- SendSQL("DELETE FROM duplicates WHERE dupe = $::FORM{'id'}");
- }
last SWITCH;
};
/^verify$/ && CheckonComment( "verify" ) && do {
@@ -1058,7 +1054,7 @@ foreach my $id (@idlist) {
"profiles $write, dependencies $write, votes $write, " .
"products READ, components READ, " .
"keywords $write, longdescs $write, fielddefs $write, " .
- "bug_group_map $write, flags $write, " .
+ "bug_group_map $write, flags $write, duplicates $write," .
"user_group_map READ, flagtypes READ, " .
"flaginclusions AS i READ, flagexclusions AS e READ, " .
"keyworddefs READ, groups READ, attachments READ");
@@ -1243,6 +1239,13 @@ foreach my $id (@idlist) {
if ($::comma ne "") {
SendSQL($query);
}
+ # Check for duplicates if the bug is [re]open
+ SendSQL("SELECT resolution FROM bugs WHERE bug_id = $id");
+ my $resolution = FetchOneColumn();
+ if ($resolution eq '') {
+ SendSQL("DELETE FROM duplicates WHERE dupe = $id");
+ }
+
my @groupAddNames = ();
foreach my $grouptoadd (@groupAdd) {
if (!BugInGroupId($id, $grouptoadd)) {