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
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Tatuya Kamada
gitlab-ce
Commits
a6ba94db
Commit
a6ba94db
authored
Apr 12, 2016
by
Phil Hughes
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Filtering by any label keeps the text on the toggle button
parent
122b4148
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
10 additions
and
1 deletion
+10
-1
app/assets/javascripts/labels_select.js.coffee
app/assets/javascripts/labels_select.js.coffee
+1
-1
spec/features/issues/filter_issues_spec.rb
spec/features/issues/filter_issues_spec.rb
+9
-0
No files found.
app/assets/javascripts/labels_select.js.coffee
View file @
a6ba94db
...
...
@@ -218,7 +218,7 @@ class @LabelsSelect
selectable
:
true
toggleLabel
:
(
selected
)
->
if
selected
and
selected
.
title
isnt
'Any Label'
if
selected
and
selected
.
title
?
selected
.
title
else
defaultLabel
...
...
spec/features/issues/filter_issues_spec.rb
View file @
a6ba94db
...
...
@@ -84,16 +84,25 @@ describe 'Filter issues', feature: true do
it
'should filter by any label'
do
find
(
'.dropdown-menu-labels a'
,
text:
'Any Label'
).
click
page
.
within
'.labels-filter'
do
expect
(
page
).
to
have_content
'Any Label'
end
expect
(
find
(
'.js-label-select .dropdown-toggle-text'
)).
to
have_content
(
'Label'
)
end
it
'should filter by no label'
do
find
(
'.dropdown-menu-labels a'
,
text:
'No Label'
).
click
page
.
within
'.labels-filter'
do
expect
(
page
).
to
have_content
'No Label'
end
expect
(
find
(
'.js-label-select .dropdown-toggle-text'
)).
to
have_content
(
'No Label'
)
end
it
'should filter by no label'
do
find
(
'.dropdown-menu-labels a'
,
text:
label
.
title
).
click
page
.
within
'.labels-filter'
do
expect
(
page
).
to
have_content
label
.
title
end
expect
(
find
(
'.js-label-select .dropdown-toggle-text'
)).
to
have_content
(
label
.
title
)
end
end
...
...
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