Sha256: 8b6367d843600a21d845f0ee002d077f8a3123f55ef093d4625fb0cbd569e659

Contents?: true

Size: 883 Bytes

Versions: 13

Compression:

Stored size: 883 Bytes

Contents

# frozen_string_literal: true

module Decidim
  module Conferences
    module Admin
      # This class contains helpers needed to format ParticipatoryProcesses
      # in order to use them in select forms for ConferenceParticipatoryProcess.
      #
      module ConferencesHelper
        # Public: A formatted collection of ParticipatoryProcesses to be used
        # in forms.
        def processes_selected
          if current_conference.present?
            @processes_selected ||= current_conference.linked_participatory_space_resources(:participatory_processes, "included_participatory_processes").pluck(:id)
          end
        end

        def assemblies_selected
          @assemblies_selected ||= current_conference.linked_participatory_space_resources(:assemblies, "included_assemblies").pluck(:id) if current_conference.present?
        end
      end
    end
  end
end

Version data entries

13 entries across 13 versions & 1 rubygems

Version Path
decidim-conferences-0.29.1 app/helpers/decidim/conferences/admin/conferences_helper.rb
decidim-conferences-0.28.4 app/helpers/decidim/conferences/admin/conferences_helper.rb
decidim-conferences-0.29.0 app/helpers/decidim/conferences/admin/conferences_helper.rb
decidim-conferences-0.28.3 app/helpers/decidim/conferences/admin/conferences_helper.rb
decidim-conferences-0.29.0.rc4 app/helpers/decidim/conferences/admin/conferences_helper.rb
decidim-conferences-0.29.0.rc3 app/helpers/decidim/conferences/admin/conferences_helper.rb
decidim-conferences-0.29.0.rc2 app/helpers/decidim/conferences/admin/conferences_helper.rb
decidim-conferences-0.29.0.rc1 app/helpers/decidim/conferences/admin/conferences_helper.rb
decidim-conferences-0.28.2 app/helpers/decidim/conferences/admin/conferences_helper.rb
decidim-conferences-0.28.1 app/helpers/decidim/conferences/admin/conferences_helper.rb
decidim-conferences-0.28.0 app/helpers/decidim/conferences/admin/conferences_helper.rb
decidim-conferences-0.28.0.rc5 app/helpers/decidim/conferences/admin/conferences_helper.rb
decidim-conferences-0.28.0.rc4 app/helpers/decidim/conferences/admin/conferences_helper.rb