Sha256: ef6f6a22738a7a624012a04667cac76d4c1e2ca0dc0f0b23442c9eb855597842

Contents?: true

Size: 1 KB

Versions: 25

Compression:

Stored size: 1 KB

Contents

# frozen_string_literal: true

module Decidim
  module Conferences
    class DownloadYourDataConferenceRegistrationSerializer < Decidim::Exporters::Serializer
      # Serializes a registration for download your data
      def serialize
        {
          id: resource.id,
          user: {
            name: resource.user.name,
            email: resource.user.email
          },
          registration_type: {
            title: resource.registration_type.title,
            price: resource.registration_type.price
          },
          conference: {
            title: resource.conference.title,
            reference: resource.conference.reference,
            slogan: resource.conference.slogan,
            description: resource.conference.description,
            start_date: resource.conference.start_date,
            end_date: resource.conference.end_date,
            location: resource.conference.location,
            objectives: resource.conference.objectives
          }
        }
      end
    end
  end
end

Version data entries

25 entries across 25 versions & 1 rubygems

Version Path
decidim-conferences-0.29.1 app/serializers/decidim/conferences/download_your_data_conference_registration_serializer.rb
decidim-conferences-0.28.4 app/serializers/decidim/conferences/download_your_data_conference_registration_serializer.rb
decidim-conferences-0.27.9 app/serializers/decidim/conferences/download_your_data_conference_registration_serializer.rb
decidim-conferences-0.29.0 app/serializers/decidim/conferences/download_your_data_conference_registration_serializer.rb
decidim-conferences-0.28.3 app/serializers/decidim/conferences/download_your_data_conference_registration_serializer.rb
decidim-conferences-0.27.8 app/serializers/decidim/conferences/download_your_data_conference_registration_serializer.rb
decidim-conferences-0.29.0.rc4 app/serializers/decidim/conferences/download_your_data_conference_registration_serializer.rb
decidim-conferences-0.29.0.rc3 app/serializers/decidim/conferences/download_your_data_conference_registration_serializer.rb
decidim-conferences-0.29.0.rc2 app/serializers/decidim/conferences/download_your_data_conference_registration_serializer.rb
decidim-conferences-0.29.0.rc1 app/serializers/decidim/conferences/download_your_data_conference_registration_serializer.rb
decidim-conferences-0.28.2 app/serializers/decidim/conferences/download_your_data_conference_registration_serializer.rb
decidim-conferences-0.27.7 app/serializers/decidim/conferences/download_your_data_conference_registration_serializer.rb
decidim-conferences-0.28.1 app/serializers/decidim/conferences/download_your_data_conference_registration_serializer.rb
decidim-conferences-0.27.6 app/serializers/decidim/conferences/download_your_data_conference_registration_serializer.rb
decidim-conferences-0.28.0 app/serializers/decidim/conferences/download_your_data_conference_registration_serializer.rb
decidim-conferences-0.27.5 app/serializers/decidim/conferences/download_your_data_conference_registration_serializer.rb
decidim-conferences-0.28.0.rc5 app/serializers/decidim/conferences/download_your_data_conference_registration_serializer.rb
decidim-conferences-0.28.0.rc4 app/serializers/decidim/conferences/download_your_data_conference_registration_serializer.rb
decidim-conferences-0.27.4 app/serializers/decidim/conferences/download_your_data_conference_registration_serializer.rb
decidim-conferences-0.27.3 app/serializers/decidim/conferences/download_your_data_conference_registration_serializer.rb