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
Boxiang Sun
gitlab-ce
Commits
0dbc5cd8
Commit
0dbc5cd8
authored
May 26, 2017
by
Tim Zallmann
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Added Dropdown + Options
parent
dddc54aa
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
42 additions
and
4 deletions
+42
-4
app/views/layouts/header/_default.html.haml
app/views/layouts/header/_default.html.haml
+42
-4
No files found.
app/views/layouts/header/_default.html.haml
View file @
0dbc5cd8
...
...
@@ -36,10 +36,48 @@
%li
=
link_to
admin_root_path
,
title:
'Admin area'
,
aria:
{
label:
"Admin area"
},
data:
{
toggle:
'tooltip'
,
placement:
'bottom'
,
container:
'body'
}
do
=
icon
(
'wrench fw'
)
%li
.header-new.dropdown
=
link_to
new_project_path
,
class:
"header-new-dropdown-toggle"
,
aria:
{
label:
"New…"
}
,
data:
{
toggle:
'dropdown'
,
placement:
'bottom'
,
container:
'body'
}
do
=
icon
(
'plus fw'
)
=
icon
(
'caret-down'
)
.dropdown-menu-nav.dropdown-menu-align-right
%ul
-
if
@group
&&
(
can?
(
current_user
,
:create_projects
,
@group
)
||
can?
(
current_user
,
:create_subgroup
,
@group
))
%li
.bold
This group
-
if
can?
(
current_user
,
:create_projects
,
@group
)
%li
=
link_to
'New project'
,
new_project_path
(
namespace_id:
@group
.
id
),
aria:
{
label:
"New project"
}
-
if
can?
(
current_user
,
:create_subgroup
,
@group
)
%li
=
link_to
'New subgroup'
,
new_group_path
(
parent_id:
@group
.
id
),
aria:
{
label:
"New subgroup"
}
-
if
@project
%li
.bold
This project
%li
=
link_to
'New issue'
,
new_namespace_project_issue_path
(
@project
.
namespace
,
@project
),
aria:
{
label:
"New issue"
}
-
merge_project
=
can?
(
current_user
,
:create_merge_request
,
@project
)
?
@project
:
(
current_user
&&
current_user
.
fork_of
(
@project
))
-
if
merge_project
%li
=
link_to
'New merge request'
,
new_namespace_project_merge_request_path
(
merge_project
.
namespace
,
merge_project
),
aria:
{
label:
"New merge request"
}
-
if
can?
(
current_user
,
:create_project_snippet
,
@project
)
%li
=
link_to
'New snippet'
,
new_namespace_project_snippet_path
(
@project
.
namespace
,
@project
),
aria:
{
label:
"New snippet"
}
-
if
@group
||
@project
%li
.divider
%li
.bold
GitLab
-
if
current_user
.
can_create_project?
%li
=
link_to
new_project_path
,
title:
'New project'
,
aria:
{
label:
"New project"
},
data:
{
toggle:
'tooltip'
,
placement:
'bottom'
,
container:
'body'
}
do
=
icon
(
'plus fw'
)
=
link_to
'New project'
,
new_project_path
,
aria:
{
label:
"New project"
}
-
if
current_user
.
can_create_group?
%li
=
link_to
'New group'
,
new_group_path
,
aria:
{
label:
"New group"
}
%li
=
link_to
'New snippet'
,
new_snippet_path
,
aria:
{
label:
"New snippet"
}
-
if
Gitlab
::
Sherlock
.
enabled?
%li
=
link_to
sherlock_transactions_path
,
title:
'Sherlock Transactions'
,
...
...
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