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
f6a8894a
Commit
f6a8894a
authored
May 19, 2017
by
Shinya Maeda
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Expose last_pipeline only when detailed status
parent
92bc1dda
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
6 additions
and
6 deletions
+6
-6
entities.rb
lib/api/entities.rb
+1
-1
pipeline_schedules.rb
lib/api/pipeline_schedules.rb
+5
-5
No files found.
lib/api/entities.rb
View file @
f6a8894a
...
@@ -690,7 +690,7 @@ module API
...
@@ -690,7 +690,7 @@ module API
expose
:id
expose
:id
expose
:description
,
:ref
,
:cron
,
:cron_timezone
,
:next_run_at
,
:active
expose
:description
,
:ref
,
:cron
,
:cron_timezone
,
:next_run_at
,
:active
expose
:created_at
,
:updated_at
,
:deleted_at
expose
:created_at
,
:updated_at
,
:deleted_at
expose
:last_pipeline
,
using:
Entities
::
PipelineBasic
expose
:last_pipeline
,
using:
Entities
::
PipelineBasic
,
if:
{
type: :full
}
expose
:owner
,
using:
Entities
::
UserBasic
expose
:owner
,
using:
Entities
::
UserBasic
end
end
...
...
lib/api/pipeline_schedules.rb
View file @
f6a8894a
...
@@ -31,7 +31,7 @@ module API
...
@@ -31,7 +31,7 @@ module API
return
not_found!
(
'PipelineSchedule'
)
unless
pipeline_schedule
return
not_found!
(
'PipelineSchedule'
)
unless
pipeline_schedule
present
pipeline_schedule
,
with:
Entities
::
PipelineSchedule
present
pipeline_schedule
,
with:
Entities
::
PipelineSchedule
,
type: :full
end
end
desc
'Creates a new pipeline schedule'
do
desc
'Creates a new pipeline schedule'
do
...
@@ -52,7 +52,7 @@ module API
...
@@ -52,7 +52,7 @@ module API
.
execute
.
execute
if
pipeline_schedule
.
persisted?
if
pipeline_schedule
.
persisted?
present
pipeline_schedule
,
with:
Entities
::
PipelineSchedule
present
pipeline_schedule
,
with:
Entities
::
PipelineSchedule
,
type: :full
else
else
render_validation_error!
(
pipeline_schedule
)
render_validation_error!
(
pipeline_schedule
)
end
end
...
@@ -75,7 +75,7 @@ module API
...
@@ -75,7 +75,7 @@ module API
return
not_found!
(
'PipelineSchedule'
)
unless
pipeline_schedule
return
not_found!
(
'PipelineSchedule'
)
unless
pipeline_schedule
if
pipeline_schedule
.
update
(
declared_params
(
include_missing:
false
))
if
pipeline_schedule
.
update
(
declared_params
(
include_missing:
false
))
present
pipeline_schedule
,
with:
Entities
::
PipelineSchedule
present
pipeline_schedule
,
with:
Entities
::
PipelineSchedule
,
type: :full
else
else
render_validation_error!
(
pipeline_schedule
)
render_validation_error!
(
pipeline_schedule
)
end
end
...
@@ -93,7 +93,7 @@ module API
...
@@ -93,7 +93,7 @@ module API
return
not_found!
(
'PipelineSchedule'
)
unless
pipeline_schedule
return
not_found!
(
'PipelineSchedule'
)
unless
pipeline_schedule
if
pipeline_schedule
.
own!
(
current_user
)
if
pipeline_schedule
.
own!
(
current_user
)
present
pipeline_schedule
,
with:
Entities
::
PipelineSchedule
present
pipeline_schedule
,
with:
Entities
::
PipelineSchedule
,
type: :full
else
else
render_validation_error!
(
pipeline_schedule
)
render_validation_error!
(
pipeline_schedule
)
end
end
...
@@ -110,7 +110,7 @@ module API
...
@@ -110,7 +110,7 @@ module API
return
not_found!
(
'PipelineSchedule'
)
unless
pipeline_schedule
return
not_found!
(
'PipelineSchedule'
)
unless
pipeline_schedule
present
pipeline_schedule
.
destroy
,
with:
Entities
::
PipelineSchedule
present
pipeline_schedule
.
destroy
,
with:
Entities
::
PipelineSchedule
,
type: :full
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