2020-06-09 15:08:05 +00:00
|
|
|
# frozen_string_literal: true
|
|
|
|
# rubocop:disable Graphql/AuthorizeTypes
|
|
|
|
|
|
|
|
module Types
|
|
|
|
class AccessLevelType < Types::BaseObject
|
|
|
|
graphql_name 'AccessLevel'
|
|
|
|
description 'Represents the access level of a relationship between a User and object that it is related to'
|
|
|
|
|
|
|
|
field :integer_value, GraphQL::INT_TYPE, null: true,
|
2021-01-22 21:09:10 +00:00
|
|
|
description: 'Integer representation of access level.',
|
2020-06-09 15:08:05 +00:00
|
|
|
method: :to_i
|
|
|
|
|
|
|
|
field :string_value, Types::AccessLevelEnum, null: true,
|
2021-01-22 21:09:10 +00:00
|
|
|
description: 'String representation of access level.',
|
2020-06-09 15:08:05 +00:00
|
|
|
method: :to_i
|
|
|
|
end
|
|
|
|
end
|