previous_changes

previous_changes()
Instance Public methods

Returns a hash of attributes that were changed before the model was saved.

person.name # => "bob"
person.name = 'robert'
person.save
person.previous_changes # => {"name" => ["bob", "robert"]}
doc_ruby_on_rails
2015-06-20 00:00:00
Comments
Leave a Comment

Please login to continue.