debian-mirror-gitlab/app/views/search/_category.html.haml

72 lines
2.6 KiB
Text
Raw Normal View History

%ul.nav-links.search-filter
2015-09-11 14:41:01 +05:30
- if @project
%li{class: ("active" if @scope == 'blobs')}
= link_to search_filter_path(scope: 'blobs') do
2016-06-02 11:05:42 +05:30
Code
%span.badge
= @search_results.blobs_count
2015-09-11 14:41:01 +05:30
%li{class: ("active" if @scope == 'issues')}
= link_to search_filter_path(scope: 'issues') do
2016-06-02 11:05:42 +05:30
Issues
%span.badge
= @search_results.issues_count
2015-09-11 14:41:01 +05:30
%li{class: ("active" if @scope == 'merge_requests')}
= link_to search_filter_path(scope: 'merge_requests') do
2016-06-02 11:05:42 +05:30
Merge requests
%span.badge
= @search_results.merge_requests_count
2015-09-25 12:07:36 +05:30
%li{class: ("active" if @scope == 'milestones')}
= link_to search_filter_path(scope: 'milestones') do
2016-06-02 11:05:42 +05:30
Milestones
%span.badge
= @search_results.milestones_count
2015-09-11 14:41:01 +05:30
%li{class: ("active" if @scope == 'notes')}
= link_to search_filter_path(scope: 'notes') do
2016-06-02 11:05:42 +05:30
Comments
%span.badge
= @search_results.notes_count
2015-09-11 14:41:01 +05:30
%li{class: ("active" if @scope == 'wiki_blobs')}
= link_to search_filter_path(scope: 'wiki_blobs') do
2016-06-02 11:05:42 +05:30
Wiki
%span.badge
= @search_results.wiki_blobs_count
2015-11-26 14:37:03 +05:30
%li{class: ("active" if @scope == 'commits')}
= link_to search_filter_path(scope: 'commits') do
2016-06-02 11:05:42 +05:30
Commits
%span.badge
= @search_results.commits_count
2015-09-11 14:41:01 +05:30
- elsif @show_snippets
%li{class: ("active" if @scope == 'snippet_blobs')}
= link_to search_filter_path(scope: 'snippet_blobs', snippets: true, group_id: nil, project_id: nil) do
2016-06-02 11:05:42 +05:30
Snippet Contents
%span.badge
= @search_results.snippet_blobs_count
2015-09-11 14:41:01 +05:30
%li{class: ("active" if @scope == 'snippet_titles')}
= link_to search_filter_path(scope: 'snippet_titles', snippets: true, group_id: nil, project_id: nil) do
2016-06-02 11:05:42 +05:30
Titles and Filenames
%span.badge
= @search_results.snippet_titles_count
2015-09-11 14:41:01 +05:30
- else
%li{class: ("active" if @scope == 'projects')}
= link_to search_filter_path(scope: 'projects') do
2016-06-02 11:05:42 +05:30
Projects
%span.badge
= @search_results.projects_count
2015-09-11 14:41:01 +05:30
%li{class: ("active" if @scope == 'issues')}
= link_to search_filter_path(scope: 'issues') do
2016-06-02 11:05:42 +05:30
Issues
%span.badge
= @search_results.issues_count
2015-09-11 14:41:01 +05:30
%li{class: ("active" if @scope == 'merge_requests')}
= link_to search_filter_path(scope: 'merge_requests') do
2016-06-02 11:05:42 +05:30
Merge requests
%span.badge
= @search_results.merge_requests_count
2015-09-25 12:07:36 +05:30
%li{class: ("active" if @scope == 'milestones')}
= link_to search_filter_path(scope: 'milestones') do
2016-06-02 11:05:42 +05:30
Milestones
%span.badge
= @search_results.milestones_count