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
ac312d73
Commit
ac312d73
authored
Sep 29, 2017
by
Grzegorz Bizon
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Move part of pipeline presenter to main CE file
parent
f963b5a9
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
10 additions
and
8 deletions
+10
-8
app/presenters/ci/pipeline_presenter.rb
app/presenters/ci/pipeline_presenter.rb
+9
-0
ee/app/presenters/ee/ci/pipeline_presenter.rb
ee/app/presenters/ee/ci/pipeline_presenter.rb
+1
-8
No files found.
app/presenters/ci/pipeline_presenter.rb
View file @
ac312d73
...
...
@@ -2,8 +2,17 @@ module Ci
class
PipelinePresenter
<
Gitlab
::
View
::
Presenter
::
Delegated
prepend
::
EE
::
Ci
::
PipelinePresenter
FAILURE_REASONS
=
EE_FAILURE_REASONS
presents
:pipeline
def
failure_reason
return
unless
pipeline
.
failure_reason?
FAILURE_REASONS
[
pipeline
.
failure_reason
.
to_sym
]
||
pipeline
.
failure_reason
end
def
status_title
if
auto_canceled?
"Pipeline is redundant and is auto-canceled by Pipeline #
#{
auto_canceled_by_id
}
"
...
...
ee/app/presenters/ee/ci/pipeline_presenter.rb
View file @
ac312d73
module
EE
module
Ci
module
PipelinePresenter
FAILURE_REASONS
=
{
EE_
FAILURE_REASONS
=
{
activity_limit_exceeded:
'Pipeline activity limit exceeded!'
,
size_limit_exceeded:
'Pipeline size limit exceeded!'
}
def
failure_reason
return
unless
pipeline
.
failure_reason?
FAILURE_REASONS
[
pipeline
.
failure_reason
.
to_sym
]
||
pipeline
.
failure_reason
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