No commit activity in last 3 years
No release in over 3 years
Implementation of saving nation numerc inputs in AR
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
 Dependencies

Development

>= 1.0.0
>= 0

Runtime

 Project Readme

Numeric Nation Input Gem for Rails 3.2

Build Status Gem Version

Info

Allow , and as decimal part delimiter for AR's float typecasting from string.

Installation

# Gemfile
gem "numeric_nation_input"

Usage

class TestModel < ActiveRecord::Base
  attr_accessible :attr1, :attr2

  numeric_nation_input :attr1, :attr2
end

model = TestModel.new(attr1: "1 025,45")
model.attr1 #=> 1025.45 (Float)