2021-01-19 21:10:45 +00:00
|
|
|
# frozen_string_literal: true
|
|
|
|
|
|
|
|
module Types
|
|
|
|
module CiConfiguration
|
|
|
|
module Sast
|
|
|
|
# rubocop: disable Graphql/AuthorizeTypes
|
|
|
|
class EntityType < BaseObject
|
|
|
|
graphql_name 'SastCiConfigurationEntity'
|
|
|
|
description 'Represents an entity in SAST CI configuration'
|
|
|
|
|
2021-07-26 12:10:08 +00:00
|
|
|
field :field, GraphQL::Types::String, null: true,
|
2021-01-19 21:10:45 +00:00
|
|
|
description: 'CI keyword of entity.'
|
|
|
|
|
2021-07-26 12:10:08 +00:00
|
|
|
field :label, GraphQL::Types::String, null: true,
|
2021-01-19 21:10:45 +00:00
|
|
|
description: 'Label for entity used in the form.'
|
|
|
|
|
2021-07-26 12:10:08 +00:00
|
|
|
field :type, GraphQL::Types::String, null: true,
|
2021-01-19 21:10:45 +00:00
|
|
|
description: 'Type of the field value.'
|
|
|
|
|
|
|
|
field :options, ::Types::CiConfiguration::Sast::OptionsEntityType.connection_type, null: true,
|
|
|
|
description: 'Different possible values of the field.'
|
|
|
|
|
2021-07-26 12:10:08 +00:00
|
|
|
field :default_value, GraphQL::Types::String, null: true,
|
2021-01-19 21:10:45 +00:00
|
|
|
description: 'Default value that is used if value is empty.'
|
|
|
|
|
2021-07-26 12:10:08 +00:00
|
|
|
field :description, GraphQL::Types::String, null: true,
|
2021-01-19 21:10:45 +00:00
|
|
|
description: 'Entity description that is displayed on the form.'
|
|
|
|
|
2021-07-26 12:10:08 +00:00
|
|
|
field :value, GraphQL::Types::String, null: true,
|
2021-01-19 21:10:45 +00:00
|
|
|
description: 'Current value of the entity.'
|
|
|
|
|
|
|
|
field :size, ::Types::CiConfiguration::Sast::UiComponentSizeEnum, null: true,
|
|
|
|
description: 'Size of the UI component.'
|
|
|
|
end
|
|
|
|
end
|
|
|
|
end
|
|
|
|
end
|