Fix failures [ci skip]

This commit is contained in:
Kamil Trzcinski 2016-11-10 17:50:55 +01:00
parent 6f6119b738
commit 8012abf4cc
3 changed files with 12 additions and 10 deletions

View file

@ -7,8 +7,8 @@ class PipelineActionEntity < Grape::Entity
expose :url do |build|
play_namespace_project_build_path(
pipeline.project.namespace,
pipeline.project,
build.project.namespace,
build.project,
build)
end
end

View file

@ -7,8 +7,8 @@ class PipelineArtifactEntity < Grape::Entity
expose :url do |build|
download_namespace_project_build_artifacts_path(
pipeline.project.namespace,
pipeline.project,
build.project.namespace,
build.project,
build)
end
end

View file

@ -4,12 +4,14 @@ class PipelineEntity < Grape::Entity
expose :id
expose :user, if: -> (pipeline, opts) { created?(pipeline, opts) }, using: UserEntity
expose :status
expose :duration
expose :finished_at
expose :stages_with_statuses, as: :stages, if: -> (pipeline, opts) { updated?(pipeline, opts) }, using: PipelineStageEntity
expose :artifacts, if: -> (pipeline, opts) { updated?(pipeline, opts) }, using: PipelineArtifactEntity
expose :manual_actions, if: -> (pipeline, opts) { updated?(pipeline, opts) }, using: PipelineActionEntity
expose :details, if: -> (pipeline, opts) { updated?(pipeline, opts) } do
expose :status
expose :duration
expose :finished_at
expose :stages_with_statuses, as: :stages, using: PipelineStageEntity
expose :artifacts, using: PipelineArtifactEntity
expose :manual_actions, using: PipelineActionEntity
end
expose :flags, if: -> (pipeline, opts) { created?(pipeline, opts) } do
expose :latest?, as: :latest