2014-01-09 05:51:20 -05:00
|
|
|
%h4
|
2014-08-27 02:57:50 -04:00
|
|
|
#{@search_results.total_count} results found
|
2014-09-05 13:30:55 -04:00
|
|
|
- unless @show_snippets
|
2014-08-29 15:22:45 -04:00
|
|
|
- if @project
|
2015-01-24 13:02:58 -05:00
|
|
|
for #{link_to @project.name_with_namespace, [@project.namespace.becomes(Namespace), @project]}
|
2014-08-29 15:22:45 -04:00
|
|
|
- elsif @group
|
|
|
|
for #{link_to @group.name, @group}
|
2014-01-09 05:51:20 -05:00
|
|
|
|
|
|
|
%hr
|
2013-11-06 02:58:43 -05:00
|
|
|
|
2014-08-28 04:06:19 -04:00
|
|
|
.row
|
|
|
|
.col-sm-3
|
|
|
|
- if @project
|
|
|
|
= render "project_filter"
|
2014-09-05 13:30:55 -04:00
|
|
|
- elsif @show_snippets
|
2014-08-29 15:22:45 -04:00
|
|
|
= render 'snippet_filter'
|
2014-08-28 04:06:19 -04:00
|
|
|
- else
|
|
|
|
= render "global_filter"
|
|
|
|
.col-sm-9
|
|
|
|
.search-results
|
|
|
|
- if @search_results.empty?
|
|
|
|
= render partial: "search/results/empty", locals: { message: "We couldn't find any matching results" }
|
|
|
|
- else
|
|
|
|
= render partial: "search/results/#{@scope.singularize}", collection: @objects
|
|
|
|
= paginate @objects, theme: 'gitlab'
|
2013-11-06 02:58:43 -05:00
|
|
|
|
|
|
|
:javascript
|
2014-08-28 04:06:19 -04:00
|
|
|
$(".search-results .term").highlight("#{escape_javascript(params[:search])}");
|