Sha256: 03f1b8782387077d55a6c41f44c53ffc34a2f29136dca8c773c8fe178266c43e

Contents?: true

Size: 693 Bytes

Versions: 33

Compression:

Stored size: 693 Bytes

Contents

# frozen_string_literal: true

module Decidim
  module Elections
    # Custom helpers, scoped to the elections engine.
    #
    module ApplicationHelper
      include Decidim::CheckBoxesTreeHelper

      def state_filter_values
        TreeNode.new(
          TreePoint.new("", t("elections.elections.filters.all", scope: "decidim")),
          [
            TreePoint.new("active", t("elections.elections.filters.active", scope: "decidim")),
            TreePoint.new("upcoming", t("elections.elections.filters.upcoming", scope: "decidim")),
            TreePoint.new("finished", t("elections.elections.filters.finished", scope: "decidim"))
          ]
        )
      end
    end
  end
end

Version data entries

33 entries across 33 versions & 1 rubygems

Version Path
decidim-elections-0.26.10 app/helpers/decidim/elections/application_helper.rb
decidim-elections-0.26.9 app/helpers/decidim/elections/application_helper.rb
decidim-elections-0.26.8 app/helpers/decidim/elections/application_helper.rb
decidim-elections-0.26.7 app/helpers/decidim/elections/application_helper.rb
decidim-elections-0.26.5 app/helpers/decidim/elections/application_helper.rb
decidim-elections-0.26.4 app/helpers/decidim/elections/application_helper.rb
decidim-elections-0.26.3 app/helpers/decidim/elections/application_helper.rb
decidim-elections-0.26.2 app/helpers/decidim/elections/application_helper.rb
decidim-elections-0.26.1 app/helpers/decidim/elections/application_helper.rb
decidim-elections-0.26.0 app/helpers/decidim/elections/application_helper.rb
decidim-elections-0.26.0.rc2 app/helpers/decidim/elections/application_helper.rb
decidim-elections-0.26.0.rc1 app/helpers/decidim/elections/application_helper.rb
decidim-elections-0.25.2 app/helpers/decidim/elections/application_helper.rb
decidim-elections-0.25.1 app/helpers/decidim/elections/application_helper.rb
decidim-elections-0.25.0 app/helpers/decidim/elections/application_helper.rb
decidim-elections-0.25.0.rc4 app/helpers/decidim/elections/application_helper.rb
decidim-elections-0.25.0.rc3 app/helpers/decidim/elections/application_helper.rb
decidim-elections-0.25.0.rc2 app/helpers/decidim/elections/application_helper.rb
decidim-elections-0.25.0.rc1 app/helpers/decidim/elections/application_helper.rb
decidim-elections-0.24.3 app/helpers/decidim/elections/application_helper.rb