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
d499d228
Commit
d499d228
authored
May 17, 2017
by
Oswaldo Ferreira
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Move related issue policies below EE-only comment
parent
8789464c
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
9 additions
and
3 deletions
+9
-3
app/policies/project_policy.rb
app/policies/project_policy.rb
+9
-3
No files found.
app/policies/project_policy.rb
View file @
d499d228
...
@@ -40,7 +40,6 @@ class ProjectPolicy < BasePolicy
...
@@ -40,7 +40,6 @@ class ProjectPolicy < BasePolicy
can!
:read_wiki
can!
:read_wiki
can!
:read_issue
can!
:read_issue
can!
:read_label
can!
:read_label
can!
:read_related_issue
can!
:read_milestone
can!
:read_milestone
can!
:read_project_snippet
can!
:read_project_snippet
can!
:read_project_member
can!
:read_project_member
...
@@ -56,6 +55,9 @@ class ProjectPolicy < BasePolicy
...
@@ -56,6 +55,9 @@ class ProjectPolicy < BasePolicy
can!
:read_pipeline_schedule
can!
:read_pipeline_schedule
can!
:read_build
can!
:read_build
end
end
# EE-only
can!
:read_related_issue
end
end
def
reporter_access!
def
reporter_access!
...
@@ -67,7 +69,6 @@ class ProjectPolicy < BasePolicy
...
@@ -67,7 +69,6 @@ class ProjectPolicy < BasePolicy
can!
:admin_issue
can!
:admin_issue
can!
:admin_label
can!
:admin_label
can!
:admin_board
can!
:admin_board
can!
:admin_related_issue
can!
:admin_list
can!
:admin_list
can!
:read_commit_status
can!
:read_commit_status
can!
:read_build
can!
:read_build
...
@@ -81,6 +82,9 @@ class ProjectPolicy < BasePolicy
...
@@ -81,6 +82,9 @@ class ProjectPolicy < BasePolicy
if
project
.
feature_available?
(
:deploy_board
)
||
Rails
.
env
.
development?
if
project
.
feature_available?
(
:deploy_board
)
||
Rails
.
env
.
development?
can!
:read_deploy_board
can!
:read_deploy_board
end
end
# EE-only
can!
:admin_related_issue
end
end
# Permissions given when an user is team member of a project
# Permissions given when an user is team member of a project
...
@@ -308,7 +312,6 @@ class ProjectPolicy < BasePolicy
...
@@ -308,7 +312,6 @@ class ProjectPolicy < BasePolicy
can!
:read_list
can!
:read_list
can!
:read_wiki
can!
:read_wiki
can!
:read_label
can!
:read_label
can!
:read_related_issue
can!
:read_milestone
can!
:read_milestone
can!
:read_project_snippet
can!
:read_project_snippet
can!
:read_project_member
can!
:read_project_member
...
@@ -324,5 +327,8 @@ class ProjectPolicy < BasePolicy
...
@@ -324,5 +327,8 @@ class ProjectPolicy < BasePolicy
# NOTE: may be overridden by IssuePolicy
# NOTE: may be overridden by IssuePolicy
can!
:read_issue
can!
:read_issue
# EE-only
can!
:read_related_issue
end
end
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