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
Jérome Perrin
gitlab-ce
Commits
60869580
Commit
60869580
authored
May 09, 2016
by
Kamil Trzcinski
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Rename image to container_registry
parent
d7b91fb5
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
7 additions
and
7 deletions
+7
-7
app/controllers/projects/container_registry_controller.rb
app/controllers/projects/container_registry_controller.rb
+3
-3
app/helpers/projects_helper.rb
app/helpers/projects_helper.rb
+2
-2
app/views/layouts/nav/_project.html.haml
app/views/layouts/nav/_project.html.haml
+2
-2
No files found.
app/controllers/projects/container_registry_controller.rb
View file @
60869580
class
Projects::ContainerRegistryController
<
Projects
::
ApplicationController
before_action
:authorize_read_
image
!
before_action
:authorize_update_
image
!
,
only:
[
:destroy
]
before_action
:authorize_read_
container_registry
!
before_action
:authorize_update_
container_registry
!
,
only:
[
:destroy
]
before_action
:tag
,
except:
[
:index
]
layout
'project'
...
...
@@ -23,6 +23,6 @@ class Projects::ContainerRegistryController < Projects::ApplicationController
end
def
tag
@tag
||=
container_registry
[
params
[
:id
]]
@tag
||=
container_registry
_repository
[
params
[
:id
]]
end
end
app/helpers/projects_helper.rb
View file @
60869580
...
...
@@ -152,8 +152,8 @@ module ProjectsHelper
nav_tabs
<<
:builds
end
if
can?
(
current_user
,
:read_
image
,
project
)
nav_tabs
<<
:
images
if
can?
(
current_user
,
:read_
container_registry
,
project
)
nav_tabs
<<
:
container_registry
end
if
can?
(
current_user
,
:admin_project
,
project
)
...
...
app/views/layouts/nav/_project.html.haml
View file @
60869580
...
...
@@ -46,9 +46,9 @@
Builds
%span
.count.builds_counter
=
number_with_delimiter
(
@project
.
builds
.
running_or_pending
.
count
(
:all
))
-
if
project_nav_tab?
:
images
-
if
project_nav_tab?
:
container_registry
=
nav_link
(
controller:
%w(container_registry)
)
do
=
link_to
project_container_registry_path
(
@project
),
title:
'Container Registry'
,
class:
'shortcuts-
images
'
do
=
link_to
project_container_registry_path
(
@project
),
title:
'Container Registry'
,
class:
'shortcuts-
container-registry
'
do
=
icon
(
'hdd-o fw'
)
%span
Container Registry
...
...
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