summaryrefslogtreecommitdiff
path: root/app/graphql/types/jira_import_type.rb
blob: ccd463370b66f49a932bf932e309c50951e9c4bc (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
# frozen_string_literal: true

module Types
  # rubocop: disable Graphql/AuthorizeTypes
  # Authorization is at project level for owners or admins,
  # so it is added directly to the Resolvers::JiraImportsResolver
  class JiraImportType < BaseObject
    graphql_name 'JiraImport'

    field :scheduled_at, Types::TimeType, null: true,
          method: :created_at,
          description: 'Timestamp of when the Jira import was created'
    field :scheduled_by, Types::UserType, null: true,
          description: 'User that started the Jira import'
    field :jira_project_key, GraphQL::STRING_TYPE, null: false,
          description: 'Project key for the imported Jira project'
  end
  # rubocop: enable Graphql/AuthorizeTypes
end