Sha256: 2d4012b88d5716dcb737d2eb20ffd393b9b0042bc246df214019f9f89dd47d87

Contents?: true

Size: 296 Bytes

Versions: 2

Compression:

Stored size: 296 Bytes

Contents

module AgilideeCommons
  module TextHelper
    def euros(n)
      number_to_currency(n)
    end
    
    def percentage(n)
      number_to_percentage(n, precision: 2, format: "%n %")
    end
    
    def text2html(str)
      h(str).gsub("\r", "").gsub("\n", "<br />").html_safe
    end
  end
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
agilidee_commons-1.0.5 app/helpers/agilidee_commons/text_helper.rb
agilidee_commons-1.0.4 app/helpers/agilidee_commons/text_helper.rb