blob: 728bc9627c55c8c4e07062e790dcdf76752b78f3 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
|
# frozen_string_literal: true
module Resolvers
module Ci
class ProjectPipelineCountsResolver < BaseResolver
type Types::Ci::PipelineCountsType, null: true
argument :ref,
GraphQL::Types::String,
required: false,
description: "Filter pipelines by the ref they are run for."
argument :sha,
GraphQL::Types::String,
required: false,
description: "Filter pipelines by the SHA of the commit they are run for."
argument :source,
GraphQL::Types::String,
required: false,
description: "Filter pipelines by their source."
def resolve(**args)
::Gitlab::PipelineScopeCounts.new(context[:current_user], object, args)
end
end
end
end
|