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

release_links_type.rb « types « graphql « app - gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: 2258adc131c594f6eb1e3bde8d21afc48fb1393f (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
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
# frozen_string_literal: true

module Types
  class ReleaseLinksType < BaseObject
    graphql_name 'ReleaseLinks'

    authorize :read_release

    alias_method :release, :object

    present_using ReleasePresenter

    field :closed_issues_url,
          GraphQL::Types::String,
          null: true,
          description: 'HTTP URL of the issues page, filtered by this release and `state=closed`.',
          authorize: :read_code
    field :closed_merge_requests_url,
          GraphQL::Types::String,
          null: true,
          description: 'HTTP URL of the merge request page , filtered by this release and `state=closed`.',
          authorize: :read_code
    field :edit_url, GraphQL::Types::String, null: true,
                                             description: "HTTP URL of the release's edit page.",
                                             authorize: :update_release
    field :merged_merge_requests_url,
          GraphQL::Types::String,
          null: true,
          description: 'HTTP URL of the merge request page , filtered by this release and `state=merged`.',
          authorize: :read_code
    field :opened_issues_url,
          GraphQL::Types::String,
          null: true,
          description: 'HTTP URL of the issues page, filtered by this release and `state=open`.',
          authorize: :read_code
    field :opened_merge_requests_url,
          GraphQL::Types::String,
          null: true,
          description: 'HTTP URL of the merge request page, filtered by this release and `state=open`.',
          authorize: :read_code
    field :self_url, GraphQL::Types::String, null: true,
                                             description: 'HTTP URL of the release.'
  end
end