Sha256: 3439585f4d21effd968311a47f67423844260f320f2e810a4f8086bc56388450
Contents?: true
Size: 716 Bytes
Versions: 7
Compression:
Stored size: 716 Bytes
Contents
# frozen_string_literal: true require "cell/partial" module Decidim module Proposals # This cell renders the cost report for a proposal. class CostReportCell < Decidim::ViewModel include ActionView::Helpers::NumberHelper include Decidim::SanitizeHelper include Decidim::LayoutHelper include ProposalCellsHelper private def cost number_to_currency(model.cost, unit: Decidim.currency_unit) end def cost_report decidim_sanitize_editor(translated_attribute(model.cost_report).html_safe) end def execution_period decidim_sanitize_editor(translated_attribute(model.execution_period).html_safe) end end end end
Version data entries
7 entries across 7 versions & 1 rubygems