Sha256: 5a1bfe474614767788433a381b5e7056f990e6395e8297cfe5eb6ac3e23b139b
Contents?: true
Size: 691 Bytes
Versions: 13
Compression:
Stored size: 691 Bytes
Contents
module Dossier module Formatter extend self extend ActiveSupport::Inflector extend ActionView::Helpers::NumberHelper def number_to_currency_from_cents(value) number_to_currency(value /= 100.0) end def url_formatter @url_formatter ||= UrlFormatter.new end delegate :url_for, :link_to, :url_helpers, to: :url_formatter class UrlFormatter include ActionView::Helpers::UrlHelper def _routes Rails.application.routes end # No controller in current context, must be specified when generating routes def controller end def url_helpers _routes.url_helpers end end end end
Version data entries
13 entries across 13 versions & 1 rubygems