Sha256: 2987d6708a46bc63c147eab77213cb2821dffe38c861b07d4437bed425fd00b3

Contents?: true

Size: 685 Bytes

Versions: 21

Compression:

Stored size: 685 Bytes

Contents

# frozen_string_literal: true

module Decidim
  module Assemblies
    module AdminLog
      module ValueTypes
        # This class presents the given value as an assembly member position.
        # Check the `DefaultPresenter` for more info on how value presenters work.
        class MemberPositionPresenter < Decidim::Log::ValueTypes::DefaultPresenter
          # Public: Presents the value as an assembly member position.
          #
          # Returns an HTML-safe String.
          def present
            return if value.blank?
            h.t(value, scope: "decidim.admin.models.assembly_member.positions", default: value)
          end
        end
      end
    end
  end
end

Version data entries

21 entries across 21 versions & 1 rubygems

Version Path
decidim-assemblies-0.18.1 app/presenters/decidim/assemblies/admin_log/value_types/member_position_presenter.rb
decidim-assemblies-0.17.2 app/presenters/decidim/assemblies/admin_log/value_types/member_position_presenter.rb
decidim-assemblies-0.18.0 app/presenters/decidim/assemblies/admin_log/value_types/member_position_presenter.rb
decidim-assemblies-0.17.1 app/presenters/decidim/assemblies/admin_log/value_types/member_position_presenter.rb
decidim-assemblies-0.16.1 app/presenters/decidim/assemblies/admin_log/value_types/member_position_presenter.rb
decidim-assemblies-0.17.0 app/presenters/decidim/assemblies/admin_log/value_types/member_position_presenter.rb
decidim-assemblies-0.16.0 app/presenters/decidim/assemblies/admin_log/value_types/member_position_presenter.rb
decidim-assemblies-0.15.2 app/presenters/decidim/assemblies/admin_log/value_types/member_position_presenter.rb
decidim-assemblies-0.15.1 app/presenters/decidim/assemblies/admin_log/value_types/member_position_presenter.rb
decidim-assemblies-0.15.0 app/presenters/decidim/assemblies/admin_log/value_types/member_position_presenter.rb
decidim-assemblies-0.14.4 app/presenters/decidim/assemblies/admin_log/value_types/member_position_presenter.rb
decidim-assemblies-0.14.3 app/presenters/decidim/assemblies/admin_log/value_types/member_position_presenter.rb
decidim-assemblies-0.14.2 app/presenters/decidim/assemblies/admin_log/value_types/member_position_presenter.rb
decidim-assemblies-0.14.1 app/presenters/decidim/assemblies/admin_log/value_types/member_position_presenter.rb
decidim-assemblies-0.13.1 app/presenters/decidim/assemblies/admin_log/value_types/member_position_presenter.rb
decidim-assemblies-0.12.2 app/presenters/decidim/assemblies/admin_log/value_types/member_position_presenter.rb
decidim-assemblies-0.13.0 app/presenters/decidim/assemblies/admin_log/value_types/member_position_presenter.rb
decidim-assemblies-0.12.1 app/presenters/decidim/assemblies/admin_log/value_types/member_position_presenter.rb
decidim-assemblies-0.13.0.pre1 app/presenters/decidim/assemblies/admin_log/value_types/member_position_presenter.rb
decidim-assemblies-0.12.0 app/presenters/decidim/assemblies/admin_log/value_types/member_position_presenter.rb