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
1
Merge Requests
1
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
nexedi
gitlab-ce
Commits
54a234e0
Commit
54a234e0
authored
Dec 10, 2019
by
Florie Guibert
Committed by
Martin Wortschack
Dec 10, 2019
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Display Labels item in sidebar when Issues are disabled
parent
607beac3
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
18 additions
and
3 deletions
+18
-3
app/views/layouts/nav/sidebar/_project.html.haml
app/views/layouts/nav/sidebar/_project.html.haml
+9
-1
changelogs/unreleased/20298-labels-management-is-not-accessible-when-issues-are-disabled.yml
...management-is-not-accessible-when-issues-are-disabled.yml
+5
-0
spec/features/projects/features_visibility_spec.rb
spec/features/projects/features_visibility_spec.rb
+4
-2
No files found.
app/views/layouts/nav/sidebar/_project.html.haml
View file @
54a234e0
...
...
@@ -144,8 +144,16 @@
%strong
.fly-out-top-item-name
=
issue_tracker
.
title
-
if
(
project_nav_tab?
:labels
)
&&
!
@project
.
issues_enabled?
=
nav_link
(
controller:
[
:labels
])
do
=
link_to
project_labels_path
(
@project
),
title:
_
(
'Labels'
),
class:
'shortcuts-labels qa-labels-items'
do
.nav-icon-container
=
sprite_icon
(
'label'
)
%span
.nav-item-name
#js-onboarding-labels-link
=
_
(
'Labels'
)
-
if
project_nav_tab?
:merge_requests
=
nav_link
(
controller:
@project
.
issues_enabled?
?
:merge_requests
:
[
:merge_requests
,
:
labels
,
:
milestones
])
do
=
nav_link
(
controller:
@project
.
issues_enabled?
?
:merge_requests
:
[
:merge_requests
,
:milestones
])
do
=
link_to
project_merge_requests_path
(
@project
),
class:
'shortcuts-merge_requests'
,
data:
{
qa_selector:
'merge_requests_link'
}
do
.nav-icon-container
=
sprite_icon
(
'git-merge'
)
...
...
changelogs/unreleased/20298-labels-management-is-not-accessible-when-issues-are-disabled.yml
0 → 100644
View file @
54a234e0
---
title
:
Display Labels item in sidebar when Issues are disabled
merge_request
:
20817
author
:
type
:
fixed
spec/features/projects/features_visibility_spec.rb
View file @
54a234e0
...
...
@@ -41,7 +41,7 @@ describe 'Edit Project Settings' do
end
context
'When external issue tracker is enabled and issues enabled on project settings'
do
it
'does not hide issues tab'
do
it
'does not hide issues tab
and hides labels tab
'
do
allow_next_instance_of
(
Project
)
do
|
instance
|
allow
(
instance
).
to
receive
(
:external_issue_tracker
).
and_return
(
JiraService
.
new
)
end
...
...
@@ -49,11 +49,12 @@ describe 'Edit Project Settings' do
visit
project_path
(
project
)
expect
(
page
).
to
have_selector
(
'.shortcuts-issues'
)
expect
(
page
).
not_to
have_selector
(
'.shortcuts-labels'
)
end
end
context
'When external issue tracker is enabled and issues disabled on project settings'
do
it
'hides issues tab'
do
it
'hides issues tab
and show labels tab
'
do
project
.
issues_enabled
=
false
project
.
save!
allow_next_instance_of
(
Project
)
do
|
instance
|
...
...
@@ -63,6 +64,7 @@ describe 'Edit Project Settings' do
visit
project_path
(
project
)
expect
(
page
).
not_to
have_selector
(
'.shortcuts-issues'
)
expect
(
page
).
to
have_selector
(
'.shortcuts-labels'
)
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