summaryrefslogtreecommitdiffstats
path: root/post_bug.cgi
diff options
context:
space:
mode:
authorterry%mozilla.org <>2000-03-24 03:22:34 +0100
committerterry%mozilla.org <>2000-03-24 03:22:34 +0100
commit4aa03da5994e4e138734f518ab3f85471a6031c8 (patch)
tree9ec5578bb9c85842be24a1c8a5a059ab10608edd /post_bug.cgi
parent71eef1691521b26b1554d9b647bee684e02e47e7 (diff)
downloadbugzilla-4aa03da5994e4e138734f518ab3f85471a6031c8.tar.gz
bugzilla-4aa03da5994e4e138734f518ab3f85471a6031c8.tar.xz
Added the concept of a "default milstone" for products, and make sure
that all products have at least that milestone defined.
Diffstat (limited to 'post_bug.cgi')
-rwxr-xr-xpost_bug.cgi11
1 files changed, 10 insertions, 1 deletions
diff --git a/post_bug.cgi b/post_bug.cgi
index 975d407d8..3c5f0698f 100755
--- a/post_bug.cgi
+++ b/post_bug.cgi
@@ -105,7 +105,8 @@ $::FORM{'reporter'} = DBNameToIdAndCheck($::FORM{'reporter'});
my @bug_fields = ("reporter", "product", "version", "rep_platform",
"bug_severity", "priority", "op_sys", "assigned_to",
- "bug_status", "bug_file_loc", "short_desc", "component");
+ "bug_status", "bug_file_loc", "short_desc", "component",
+ "target_milestone");
if (Param("useqacontact")) {
SendSQL("select initialqacontact from components where program=" .
@@ -139,11 +140,19 @@ if (!exists $::FORM{'bug_status'}) {
}
}
+if (!exists $::FORM{'target_milestone'}) {
+ SendSQL("SELECT defaultmilestone FROM products " .
+ "WHERE product = " . SqlQuote($::FORM{'product'}));
+ $::FORM{'target_milestone'} = FetchOneColumn();
+}
+
if ( Param("strictvaluechecks") ) {
GetVersionTable();
CheckFormField(\%::FORM, 'reporter');
CheckFormField(\%::FORM, 'product', \@::legal_product);
CheckFormField(\%::FORM, 'version', \@{$::versions{$::FORM{'product'}}});
+ CheckFormField(\%::FORM, 'target_milestone',
+ \@{$::target_milestone{$::FORM{'product'}}});
CheckFormField(\%::FORM, 'rep_platform', \@::legal_platform);
CheckFormField(\%::FORM, 'bug_severity', \@::legal_severity);
CheckFormField(\%::FORM, 'priority', \@::legal_priority);