Sha256: c0d8f3945a31785d977e49bf7dfb0161f78139403b380b7064cf37a0d1112123

Contents?: true

Size: 940 Bytes

Versions: 10

Compression:

Stored size: 940 Bytes

Contents

# frozen_string_literal: true

module Decidim
  module Forms
    QuestionnaireType = GraphQL::ObjectType.define do
      name "Questionnaire"
      description "A questionnaire"

      interfaces [
        -> { Decidim::Core::TimestampsInterface }
      ]

      field :id, !types.ID, "ID of this questionnaire"
      field :title, !Decidim::Core::TranslatedFieldType, "The title of this questionnaire."
      field :description, Decidim::Core::TranslatedFieldType, "The description of this questionnaire."
      field :tos, Decidim::Core::TranslatedFieldType, "The Terms of Service for this questionnaire."
      field :forType, types.String, "Type of entity using this questionnaire.", property: :questionnaire_for_type
      field :forEntity, QuestionnaireEntityInterface, "Entity using this questionnaire.", property: :questionnaire_for
      field :questions, !types[QuestionType], "Questions in this questionnaire."
    end
  end
end

Version data entries

10 entries across 10 versions & 1 rubygems

Version Path
decidim-forms-0.23.6 app/types/decidim/forms/questionnaire_type.rb
decidim-forms-0.23.5 app/types/decidim/forms/questionnaire_type.rb
decidim-forms-0.23.4 app/types/decidim/forms/questionnaire_type.rb
decidim-forms-0.23.3 app/types/decidim/forms/questionnaire_type.rb
decidim-forms-0.23.2 app/types/decidim/forms/questionnaire_type.rb
decidim-forms-0.23.1 app/types/decidim/forms/questionnaire_type.rb
decidim-forms-0.23.1.rc1 app/types/decidim/forms/questionnaire_type.rb
decidim-forms-0.23.0 app/types/decidim/forms/questionnaire_type.rb
decidim-forms-0.22.0 app/types/decidim/forms/questionnaire_type.rb
decidim-forms-0.21.0 app/types/decidim/forms/questionnaire_type.rb