summaryrefslogtreecommitdiffstats
path: root/Bugzilla
diff options
context:
space:
mode:
authormkanat%bugzilla.org <>2009-12-17 22:47:58 +0100
committermkanat%bugzilla.org <>2009-12-17 22:47:58 +0100
commitdcca89e5e6ba556f8dc61bc5337434158f2adbad (patch)
tree0e8a84c2615dd75fa432c7f9ca870373e505eefd /Bugzilla
parent9d6f961beaecf07741c2221146ed2c17e9c07594 (diff)
downloadbugzilla-dcca89e5e6ba556f8dc61bc5337434158f2adbad.tar.gz
bugzilla-dcca89e5e6ba556f8dc61bc5337434158f2adbad.tar.xz
Bug 518459: Remove certain QuickSearch features that are no longer needed (after the re-work) and may be confusing
Patch by Max Kanat-Alexander <mkanat@bugzilla.org> r=LpSolit, a=LpSolit
Diffstat (limited to 'Bugzilla')
-rw-r--r--Bugzilla/Search/Quicksearch.pm46
1 files changed, 2 insertions, 44 deletions
diff --git a/Bugzilla/Search/Quicksearch.pm b/Bugzilla/Search/Quicksearch.pm
index 54bff71c2..bef463a3c 100644
--- a/Bugzilla/Search/Quicksearch.pm
+++ b/Bugzilla/Search/Quicksearch.pm
@@ -110,8 +110,6 @@ use constant FIELD_OPERATOR => {
};
# 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]
# ^^^
@@ -273,22 +271,6 @@ sub _handle_status_and_resolution {
elsif ($words->[0] eq 'OPEN') {
shift @$words;
}
- elsif ($words->[0] =~ /^\+[A-Z]+(,[A-Z]+)*$/) {
- # e.g. +DUP,FIX
- if (matchPrefixes(\%states,
- \%resolutions,
- [split(/,/, substr($words->[0], 1))],
- \@closedStates,
- $legal_resolutions)) {
- shift @$words;
- # Allowing additional resolutions means we need to keep
- # the "no resolution" resolution.
- $resolutions{'---'} = 1;
- }
- else {
- # Carry on if no match found.
- }
- }
elsif ($words->[0] =~ /^[A-Z]+(,[A-Z]+)*$/) {
# e.g. NEW,ASSI,REOP,FIX
undef %states;
@@ -326,10 +308,6 @@ sub _handle_special_first_chars {
my $baseWord = substr($qsword, 1);
my @subWords = split(/[\|,]/, $baseWord);
- if ($firstChar eq '+') {
- addChart('short_desc', 'substring', $_, $negate) foreach (@subWords);
- return 1;
- }
if ($firstChar eq '#') {
addChart('short_desc', 'substring', $baseWord, $negate);
addChart('content', 'matches', $baseWord, $negate);
@@ -458,27 +436,14 @@ sub _translate_field_name {
sub _special_field_syntax {
my ($word, $negate) = @_;
- # Platform and operating system
- if (grep { lc($word) eq $_ } PLATFORMS
- or grep { lc($word) eq $_ } OPSYSTEMS)
- {
- addChart('rep_platform', 'substring', $word, $negate);
- addChart('op_sys', 'substring', $word, $negate);
- return 1;
- }
- # Priority
- my $legal_priorities = get_legal_field_values('priority');
- if (grep { lc($_) eq lc($word) } @$legal_priorities) {
- addChart('priority', 'equals', $word, $negate);
- return 1;
- }
-
# P1-5 Syntax
if ($word =~ m/^P(\d+)(?:-(\d+))?$/i) {
my $start = $1 - 1;
$start = 0 if $start < 0;
my $end = $2 - 1;
+
+ my $legal_priorities = get_legal_field_values('priority');
$end = scalar(@$legal_priorities) - 1
if $end > (scalar @$legal_priorities - 1);
my $prios = $legal_priorities->[$start];
@@ -489,13 +454,6 @@ sub _special_field_syntax {
return 1;
}
- # Severity
- my $legal_severities = get_legal_field_values('bug_severity');
- if (grep { lc($word) eq substr($_, 0, 3)} @$legal_severities) {
- addChart('bug_severity', 'substring', $word, $negate);
- return 1;
- }
-
# Votes (votes>xx)
if ($word =~ m/^votes>([0-9]+)$/) {
addChart('votes', 'greaterthan', $1, $negate);