Sha256: d97131c6ea533701d43da6bb587c117b16ffef93221ad5b2217aee6f3ebcf3cc
Contents?: true
Size: 1008 Bytes
Versions: 18
Compression:
Stored size: 1008 Bytes
Contents
# frozen_string_literal: true module Decidim module Accountability module AdminLog # This class holds the logic to present a `Decidim::Accountability::Status` # for the `AdminLog` log. # # Usage should be automatic and you should not need to call this class # directly, but here is an example: # # action_log = Decidim::ActionLog.last # view_helpers # => this comes from the views # StatusPresenter.new(action_log, view_helpers).present class StatusPresenter < Decidim::Log::BasePresenter private def action_string case action when "create", "delete", "update" "decidim.accountability.admin_log.status.#{action}" else super end end def diff_fields_mapping { key: :string, name: :i18n, description: :i18n, progress: :integer } end end end end end
Version data entries
18 entries across 18 versions & 1 rubygems