BigW Consortium Gitlab
Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
G
gitlab-ce
Project
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Open sidebar
Forest Godfrey
gitlab-ce
Commits
1381b4f4
Unverified
Commit
1381b4f4
authored
Jun 10, 2016
by
Connor Shea
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix displaying of project settings links the user cannot access.
parent
37be2007
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
10 additions
and
8 deletions
+10
-8
_project.html.haml
app/views/layouts/nav/_project.html.haml
+2
-1
_project_settings.html.haml
app/views/layouts/nav/_project_settings.html.haml
+8
-7
No files found.
app/views/layouts/nav/_project.html.haml
View file @
1381b4f4
-
if
current_user
.controls
-
access
=
user_max_access_in_project
(
current_user
.
id
,
@project
)
-
can_edit
=
can?
(
current_user
,
:admin_project
,
@project
)
.controls
.dropdown.project-settings-dropdown
%a
.dropdown-new.btn.btn-default
#project-settings-button
{
href:
'#'
,
'data-toggle'
=>
'dropdown'
}
=
icon
(
'cog'
)
=
icon
(
'caret-down'
)
%ul
.dropdown-menu.dropdown-menu-align-right
=
render
'layouts/nav/project_settings'
-
if
can_edit
||
access
%li
.divider
-
if
can_edit
%li
...
...
app/views/layouts/nav/_project_settings.html.haml
View file @
1381b4f4
-
access
=
user_max_access_in_project
(
current_user
.
id
,
@project
)
-
if
project_nav_tab?
:team
=
nav_link
(
controller:
[
:project_members
,
:teams
])
do
=
link_to
namespace_project_project_members_path
(
@project
.
namespace
,
@project
),
title:
'Members'
,
class:
'team-tab tab'
do
%span
Members
-
if
@project
.
allowed_to_share_with_group?
-
if
access
-
if
@project
.
allowed_to_share_with_group?
=
nav_link
(
controller: :group_links
)
do
=
link_to
namespace_project_group_links_path
(
@project
.
namespace
,
@project
),
title:
"Groups"
do
%span
Groups
=
nav_link
(
controller: :deploy_keys
)
do
=
nav_link
(
controller: :deploy_keys
)
do
=
link_to
namespace_project_deploy_keys_path
(
@project
.
namespace
,
@project
),
title:
'Deploy Keys'
do
%span
Deploy Keys
=
nav_link
(
controller: :hooks
)
do
=
nav_link
(
controller: :hooks
)
do
=
link_to
namespace_project_hooks_path
(
@project
.
namespace
,
@project
),
title:
'Webhooks'
do
%span
Webhooks
=
nav_link
(
controller: :services
)
do
=
nav_link
(
controller: :services
)
do
=
link_to
namespace_project_services_path
(
@project
.
namespace
,
@project
),
title:
'Services'
do
%span
Services
=
nav_link
(
controller: :protected_branches
)
do
=
nav_link
(
controller: :protected_branches
)
do
=
link_to
namespace_project_protected_branches_path
(
@project
.
namespace
,
@project
),
title:
'Protected Branches'
do
%span
Protected Branches
-
if
@project
.
builds_enabled?
-
if
@project
.
builds_enabled?
=
nav_link
(
controller: :runners
)
do
=
link_to
namespace_project_runners_path
(
@project
.
namespace
,
@project
),
title:
'Runners'
do
%span
...
...
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