Class: View::Percentage

Inherits:
Formatter show all
Defined in:
lib/view/formatters/percentage.rb

Overview

Uses the number_to_percentage helper

Instance Attribute Summary

Attributes inherited from Formatter

#block, #template, #value

Instance Method Summary (collapse)

Methods inherited from Formatter

#all_options, as, #format!, inherited, #options, skip_blank_formatter, #to_s, type

Instance Method Details

- (Object) format



9
10
11
# File 'lib/view/formatters/percentage.rb', line 9

def format
  template.number_to_percentage(value, options)
end