|
a/Allura/allura/ext/search/search_main.py |
|
b/Allura/allura/ext/search/search_main.py |
|
... |
|
... |
56 |
pids = [c.project._id] + [
|
56 |
pids = [c.project._id] + [
|
57 |
p._id for p in c.project.subprojects ]
|
57 |
p._id for p in c.project.subprojects ]
|
58 |
project_match = ' OR '.join(
|
58 |
project_match = ' OR '.join(
|
59 |
'project_id_s:%s' % pid
|
59 |
'project_id_s:%s' % pid
|
60 |
for pid in pids )
|
60 |
for pid in pids )
|
61 |
search_query = '%s AND is_history_b:%s AND (%s)' % (
|
61 |
search_query = '%s AND is_history_b:%s AND (%s) AND -deleted_b:true' % (
|
62 |
q, history, project_match)
|
62 |
q, history, project_match)
|
63 |
results = search.search(search_query, is_history_b=history)
|
63 |
results = search.search(search_query, is_history_b=history)
|
64 |
if results: count=results.hits
|
64 |
if results: count=results.hits
|
65 |
return dict(q=q, history=history, results=results or [], count=count)
|
65 |
return dict(q=q, history=history, results=results or [], count=count)
|
66 |
|
66 |
|