find a specific bug shouldn't allow empty search

RESOLVED FIXED in Bugzilla 3.0

Status

()

Bugzilla
Query/Bug List
RESOLVED FIXED
15 years ago
11 years ago

People

(Reporter: asa, Assigned: Frédéric Buclin)

Tracking

({perf})

2.17.6
Bugzilla 3.0
Bug Flags:
approval +
approval3.0 +

Details

Attachments

(1 attachment)

(Reporter)

Description

15 years ago
Tested at b.m.o:

The new "find a specific bug" query interface allows a user to submit a query
with no "Words" filled in. Even if it's not a serious hit on the database or the
application, it can't possibly return useful results so it should be prevented.
(It returns a standard buglist of all open bugs.)

Possible solutions: 
1. disable the submit button until some words are entered in the "words" field.
2. throw an alert to inform the user that he must enter some words to proceed.
3. insert into the page some highly-visible warning text to inform the user that
he must enter some words to proceed. 

This is the search that's submitted when the "words" field is left empty:

SELECT bugs.bug_id, bugs.bug_severity, bugs.priority, bugs.bug_status,
bugs.resolution, bugs.delta_ts, map_assigned_to.login_name, bugs.bug_status,
bugs.resolution, bugs.op_sys, bugs.short_desc FROM bugs, profiles AS
map_assigned_to LEFT JOIN bug_group_map ON bug_group_map.bug_id = bugs.bug_id
AND bug_group_map.group_id NOT IN (9,5,10,3,2,1,11,4,14,13,12,6,8,7) LEFT JOIN
cc ON cc.bug_id = bugs.bug_id AND cc.who = 5003 WHERE bugs.assigned_to =
map_assigned_to.userid AND (bugs.bug_status IN
('UNCONFIRMED','NEW','ASSIGNED','REOPENED')) AND ((bug_group_map.group_id IS
NULL) OR (bugs.reporter_accessible = 1 AND bugs.reporter = 5003) OR
(bugs.cclist_accessible = 1 AND cc.who IS NOT NULL) OR (bugs.assigned_to = 5003)
OR (bugs.qa_contact = 5003) ) GROUP BY bugs.bug_id ORDER BY bugs.bug_status,
bugs.priority, map_assigned_to.login_name, bugs.bug_id
Reassigning bugs that I'm not actively working on to the default component owner
in order to try to make some sanity out of my personal buglist.  This doesn't
mean the bug isn't being dealt with, just that I'm not the one doing it.  If you
are dealing with this bug, please assign it to yourself.
Assignee: justdave → query-and-buglist
QA Contact: mattyt-bugzilla → default-qa
(Assignee)

Updated

12 years ago
Duplicate of this bug: 372092
(Assignee)

Updated

12 years ago
Keywords: perf
OS: Windows XP → All
Hardware: PC → All
Target Milestone: --- → Bugzilla 3.0
(Assignee)

Comment 3

12 years ago
Created attachment 256777 [details] [diff] [review]
patch, v1
Assignee: query-and-buglist → LpSolit
Status: NEW → ASSIGNED
Attachment #256777 - Flags: review?(justdave)
Comment on attachment 256777 [details] [diff] [review]
patch, v1

Hmm, the implied else in the JS looks strange to me, but it works, and doesn't generate any errors on my JS console.  This does what it says. :)
Attachment #256777 - Flags: review?(justdave) → review+
Flags: approval3.0+
Flags: approval+
(Assignee)

Comment 5

12 years ago
tip:

Checking in buglist.cgi;
/cvsroot/mozilla/webtools/bugzilla/buglist.cgi,v  <--  buglist.cgi
new revision: 1.353; previous revision: 1.352
done
Checking in template/en/default/search/search-specific.html.tmpl;
/cvsroot/mozilla/webtools/bugzilla/template/en/default/search/search-specific.html.tmpl,v  <--  search-specific.html.tmpl
new revision: 1.21; previous revision: 1.20
done


3.0 RC1:

Checking in buglist.cgi;
/cvsroot/mozilla/webtools/bugzilla/buglist.cgi,v  <--  buglist.cgi
new revision: 1.351.2.1; previous revision: 1.351
done
Checking in template/en/default/search/search-specific.html.tmpl;
/cvsroot/mozilla/webtools/bugzilla/template/en/default/search/search-specific.html.tmpl,v  <--  search-specific.html.tmpl
new revision: 1.20.2.1; previous revision: 1.20
done
Status: ASSIGNED → RESOLVED
Last Resolved: 12 years ago
Resolution: --- → FIXED
(Assignee)

Updated

12 years ago
Duplicate of this bug: 372092

Comment 7

11 years ago
It will be better to have this as a "Parameter" so that a site admin can choose to enable/disable "empty search". 

Comment 8

11 years ago
Filed bug #385910 that would add a "parameter" to disable/enable the use of "empty search".
You need to log in before you can comment on or make changes to this bug.