Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'lib/api/deployments.rb')
-rw-r--r--lib/api/deployments.rb10
1 files changed, 9 insertions, 1 deletions
diff --git a/lib/api/deployments.rb b/lib/api/deployments.rb
index 141f089b5e1..3a0eea677b8 100644
--- a/lib/api/deployments.rb
+++ b/lib/api/deployments.rb
@@ -50,6 +50,14 @@ module API
type: DateTime,
desc: 'Return deployments updated before the specified date. Expected in ISO 8601 format (`2019-03-15T08:00:00Z`)'
+ optional :finished_after,
+ type: DateTime,
+ desc: 'Return deployments finished after the specified date. Expected in ISO 8601 format (`2019-03-15T08:00:00Z`)'
+
+ optional :finished_before,
+ type: DateTime,
+ desc: 'Return deployments finished before the specified date. Expected in ISO 8601 format (`2019-03-15T08:00:00Z`)'
+
optional :environment,
type: String,
desc: 'The name of the environment to filter deployments by'
@@ -64,7 +72,7 @@ module API
authorize! :read_deployment, user_project
deployments =
- DeploymentsFinder.new(params.merge(project: user_project))
+ DeploymentsFinder.new(declared_params(include_missing: false).merge(project: user_project))
.execute.with_api_entity_associations
present paginate(deployments), with: Entities::Deployment