49c83155cc
Querying all counts for the different search results in the same request led to timeouts, so we now only calculate the count for the *current* search results, and request the others in separate asynchronous calls.
35 lines
1.6 KiB
Text
35 lines
1.6 KiB
Text
- users = capture_haml do
|
|
- if search_tabs?(:members)
|
|
= search_filter_link 'users', _("Users")
|
|
|
|
.scrolling-tabs-container.inner-page-scroll-tabs.is-smaller
|
|
.fade-left= icon('angle-left')
|
|
.fade-right= icon('angle-right')
|
|
%ul.nav-links.search-filter.scrolling-tabs.nav.nav-tabs
|
|
- if @project
|
|
- if project_search_tabs?(:blobs)
|
|
= search_filter_link 'blobs', _("Code"), data: { qa_selector: 'code_tab' }
|
|
- if project_search_tabs?(:issues)
|
|
= search_filter_link 'issues', _("Issues")
|
|
- if project_search_tabs?(:merge_requests)
|
|
= search_filter_link 'merge_requests', _("Merge requests")
|
|
- if project_search_tabs?(:milestones)
|
|
= search_filter_link 'milestones', _("Milestones")
|
|
- if project_search_tabs?(:notes)
|
|
= search_filter_link 'notes', _("Comments")
|
|
- if project_search_tabs?(:wiki)
|
|
= search_filter_link 'wiki_blobs', _("Wiki")
|
|
- if project_search_tabs?(:commits)
|
|
= search_filter_link 'commits', _("Commits")
|
|
= users
|
|
|
|
- elsif @show_snippets
|
|
= search_filter_link 'snippet_blobs', _("Snippet Contents"), search: { snippets: true, group_id: nil, project_id: nil }
|
|
= search_filter_link 'snippet_titles', _("Titles and Filenames"), search: { snippets: true, group_id: nil, project_id: nil }
|
|
- else
|
|
= search_filter_link 'projects', _("Projects")
|
|
= search_filter_link 'issues', _("Issues")
|
|
= search_filter_link 'merge_requests', _("Merge requests")
|
|
= search_filter_link 'milestones', _("Milestones")
|
|
= render_if_exists 'search/category_elasticsearch'
|
|
= users
|