]> git.ipfire.org Git - thirdparty/bugzilla.git/commitdiff
Patch for bug 233049: Improve error when filtering requests with component not in...
authorjocuri%softhome.net <>
Thu, 9 Dec 2004 17:22:03 +0000 (17:22 +0000)
committerjocuri%softhome.net <>
Thu, 9 Dec 2004 17:22:03 +0000 (17:22 +0000)
request.cgi
template/en/default/global/code-error.html.tmpl

index 047c4fa1437d35b5dffa3efa28ff811f3289b9a4..cffad983fa1139f4ebf45e90fdfb3081e4dc9722 100755 (executable)
@@ -168,10 +168,11 @@ sub queue {
                     push(@criteria, "bugs.component_id = $component_id");
                     push(@excluded_columns, 'component') unless $cgi->param('do_union');
                 }
-                else { ThrowCodeError("unknown_component", { component => $cgi->param('component') }) }
+                else { ThrowUserError("component_not_valid", { 'product' => $cgi->param('product'),
+                                                               'name' => $cgi->param('component') }) }
             }
         }
-        else { ThrowCodeError("unknown_product", { product => $cgi->param('product') }) }
+        else { ThrowUserError("product_doesnt_exist", { 'product' => $cgi->param('product') }) }
     }
     
     # Filter results by flag types.
index c5233b8e88dfd90443e3f86703f6073f18805e4b..7919471357147f9b7f121b242608209eb17e9203 100644 (file)
        I could not figure out what you wanted to do.
     [% END %]
 
-  [% ELSIF error == "unknown_component" %]
-    [% title = "Unknown Component" %]
-    There is no component named <em>[% component FILTER html %]</em>.
-
-  [% ELSIF error == "unknown_product" %]
-    [% title = "Unknown Product" %]
-    There is no product named <em>[% product FILTER html %]</em>.
-
   [% ELSE %]
     [% title = "Internal error" %]
     An internal error has occured, but [% terms.Bugzilla %] doesn't know