method

convert

Importance_0
convert() public

No documentation

This method has no description. You can help the Ruby on Rails community by adding new notes.

Hide source
# File activesupport/lib/active_support/number_helper/number_to_currency_converter.rb, line 8
      def convert
        number = self.number.to_s.strip
        format = options[:format]

        if number.to_f.negative?
          format = options[:negative_format]
          number = absolute_value(number)
        end

        rounded_number = NumberToRoundedConverter.convert(number, options)
        format.gsub('%n'.freeze, rounded_number).gsub('%u'.freeze, options[:unit])
      end
Register or log in to add new notes.