Module: L10n::NumericColumnConversions
- Defined in:
- lib/l10n/numeric_column_conversions.rb
Instance Method Summary collapse
Instance Method Details
#from_user(name, value, type, original_attribute = nil) ⇒ Object
6 7 8 9 10 11 |
# File 'lib/l10n/numeric_column_conversions.rb', line 6 def from_user(name, value, type, original_attribute = nil) if [:integer, :float, :decimal].include?(type.try(:type)) && value.is_a?(String) value = Numeric.delocalize(value) end super(name, value, type, original_attribute) end |