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

work_item_state_counts_resolver.rb « resolvers « graphql « app - gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: 93551a57694fe4012ec7aa3996b55a200fd9a847 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
# frozen_string_literal: true

module Resolvers
  class WorkItemStateCountsResolver < WorkItemsResolver
    type Types::WorkItemStateCountsType, null: true

    def resolve(**args)
      return if resource_parent.nil?

      work_item_finder = finder(prepare_finder_params(args))
      work_item_finder.parent_param = resource_parent

      Gitlab::IssuablesCountForState.new(work_item_finder, resource_parent)
    end
  end
end