Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gitlab-ce
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
gitlab-ce
Commits
6c69868c
Commit
6c69868c
authored
Mar 11, 2016
by
Phil Hughes
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Improved search results filter dropdown
parent
f7da99ae
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
30 additions
and
16 deletions
+30
-16
app/views/search/_filter.html.haml
app/views/search/_filter.html.haml
+30
-16
No files found.
app/views/search/_filter.html.haml
View file @
6c69868c
...
...
@@ -6,14 +6,21 @@
-
else
Any
%b
.caret
%ul
.dropdown-menu
%li
=
link_to
search_filter_path
(
group_id:
nil
)
do
Any
-
current_user
.
authorized_groups
.
sort_by
(
&
:name
).
each
do
|
group
|
%li
=
link_to
search_filter_path
(
group_id:
group
.
id
,
project_id:
nil
)
do
=
group
.
name
.dropdown-menu.dropdown-select.dropdown-menu-selectable
.dropdown-title
%span
Filter results by group
%button
.dropdown-title-button.dropdown-menu-close
{
aria:
{
label:
"Close"
}}
=
icon
(
'times'
)
.dropdown-content
%ul
%li
=
link_to
search_filter_path
(
group_id:
nil
),
class:
(
"is-active"
if
!
params
[
:group_id
].
present?
)
do
Any
%li
.divider
-
current_user
.
authorized_groups
.
sort_by
(
&
:name
).
each
do
|
group
|
%li
=
link_to
search_filter_path
(
group_id:
group
.
id
,
project_id:
nil
),
class:
(
"is-active"
if
params
[
:group_id
]
==
group
.
id
.
to_s
)
do
=
group
.
name
.dropdown.inline.prepend-left-10.project-filter
%button
.dropdown-toggle.btn.btn-sm
{
type:
'button'
,
'data-toggle'
=>
'dropdown'
}
...
...
@@ -23,11 +30,18 @@
-
else
Any
%b
.caret
%ul
.dropdown-menu
%li
=
link_to
search_filter_path
(
project_id:
nil
)
do
Any
-
current_user
.
authorized_projects
.
sort_by
(
&
:name_with_namespace
).
each
do
|
project
|
%li
=
link_to
search_filter_path
(
project_id:
project
.
id
,
group_id:
nil
)
do
=
project
.
name_with_namespace
.dropdown-menu.dropdown-select.dropdown-menu-selectable
.dropdown-title
%span
Filter results by project
%button
.dropdown-title-button.dropdown-menu-close
{
aria:
{
label:
"Close"
}}
=
icon
(
'times'
)
.dropdown-content
%ul
%li
=
link_to
search_filter_path
(
project_id:
nil
),
class:
(
"is-active"
if
!
params
[
:project_id
].
present?
)
do
Any
%li
.divider
-
current_user
.
authorized_projects
.
sort_by
(
&
:name_with_namespace
).
each
do
|
project
|
%li
=
link_to
search_filter_path
(
project_id:
project
.
id
,
group_id:
nil
),
class:
(
"is-active"
if
params
[
:project_id
]
==
project
.
id
.
to_s
)
do
=
project
.
name_with_namespace
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment