Changed attributes plugin
Plugin details
Documentation
Install the plugin:
ruby script/plugin install http://svn.behindlogic.com/public/rails/plugins/changed_attributes/
Examples below
p = Person.find(1) => p.changed_attributes => {} p.name = 'Joe Smith' p.changed_attributes => {'name' => 'Joe Smith'} p.revert_attribute(:name) p.name => "Danl Boone" p.age = 59 p.save_if_modified => true p.save_if_modified => false p.age = 220 p.attr_changed?(:age) => true p.revert p.age => 59 p.destroy p.new_record? => false p.id => 1 p.exists? => false p.save => true
Further Documentation
There is currently no advanced documentation for this plugin.
New documentationEdit plugin | Back in time (1 older version) | Last edited by: Guest, 8 months ago

