summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorlpsolit%gmail.com <>2007-03-25 19:31:35 +0200
committerlpsolit%gmail.com <>2007-03-25 19:31:35 +0200
commitceb1430e9a728ab7cda0a59d74cfa074c6997b32 (patch)
tree23031bce53facc0263897187f0cc177b5852a0e8
parent6fd079eafd176f357b109e32d2f1f7e99e70ef18 (diff)
downloadbugzilla-ceb1430e9a728ab7cda0a59d74cfa074c6997b32.tar.gz
bugzilla-ceb1430e9a728ab7cda0a59d74cfa074c6997b32.tar.xz
Bug 371475: Quicksearch should include OS field (in addition to Platform field) by default - Patch by Teemu Mannermaa <wicked+bz@etlicon.fi> r/a=LpSolit
-rw-r--r--Bugzilla/Search/Quicksearch.pm8
1 files changed, 6 insertions, 2 deletions
diff --git a/Bugzilla/Search/Quicksearch.pm b/Bugzilla/Search/Quicksearch.pm
index 4145ff7c4..dfab63698 100644
--- a/Bugzilla/Search/Quicksearch.pm
+++ b/Bugzilla/Search/Quicksearch.pm
@@ -91,6 +91,7 @@ use constant MAPPINGS => {
# We might want to put this into localconfig or somewhere
use constant PLATFORMS => ('pc', 'sun', 'macintosh', 'mac');
+use constant OPSYSTEMS => ('windows', 'win', 'linux');
use constant PRODUCT_EXCEPTIONS => (
'row', # [Browser]
# ^^^
@@ -288,10 +289,13 @@ sub quicksearch {
# Having ruled out the special cases, we may now split
# by comma, which is another legal boolean OR indicator.
foreach my $word (split(/,/, $or_operand)) {
- # Platform
- if (grep({lc($word) eq $_} PLATFORMS)) {
+ # Platform and operating system
+ if (grep({lc($word) eq $_} PLATFORMS)
+ || grep({lc($word) eq $_} OPSYSTEMS)) {
addChart('rep_platform', 'substring',
$word, $negate);
+ addChart('op_sys', 'substring',
+ $word, $negate);
}
# Priority
elsif ($word =~ m/^[pP]([1-5](-[1-5])?)$/) {