- Fixed callback registration to not register duplicate destroy/autosave callbacks. Fixes #14.
- [BREAKING] Drop ruby 1.9.3 support.
- [BREAKING] Drop rails 3.2 support.
- Better dependency declarations.
- Add Ruby 2.2 support.
- Add Rails 4.2 support.
- Add Rails 5 (edge) support.
- Fix an error with
HashWithIndifferentAccess
in Rails 4.2
- Forces callbacks into an array before trying to add Secretary callbacks. This fixes compatibility with
ar-octopus
library. - Fixed an error where
tracks_association
was raisingNotImplementError
if:dependent
was defined on the association. (#12) - Fixes migration-copy generator.
- Now being tested with Rails 4-1-stable and 4-2-head
- Humanized attributes in Version Description.
- Activities association is now added to the User class automatically.
- Automatically add the foreign key to versioned attributes for a belongs_to
association. Before, it was only adding the association name, which caused
a version not to be created when updating a belongs_to association via a form
if the foreign key wasn't in the
versioned_attributes
list. - Fixed migration generator
- Fixes bug where db:schema:load couldn't run if the user class specified versioned attributes.
- Only add an attribute to
versioned_changes
if it changed significantly. This fixes the problem where ahas_one
association was creating a version no matter what.
- Use memoized
versioned_changes
in callbacks for performance optimization. - Only create a version if
versioned_changes
is present. The previous behavior was to create a version ifchanged?
was true, which was creating empty versions (becausechanged?
could be true for an attribute that we're not versioning)
- Make sure assigning nested attributes only makes the model dirty for tracked associations.
- Fixed error where adding an inherited class to a collection association.
- Rescue when assigning nested attributes so that
db:schema:load
can be called properly.
#versioned_attributes=
will now raise an error if you pass it anything but an array of strings. This is to prevent someone from passing in symbols and getting subtle bugs.
- [BREAKING] Remove custom_changes, instead we're just using the ActiveModel::Dirty interface.
- A bunch of additional tests for:
- has_many :through
- has_and_belongs_to_many
- MySQL
- PostgreSQL
- Lots of additional documentation
- Refactored some code to clean up has_secretary module. Moved Dirty Attribute methods into their own module, where (eventually) the full ActiveModel::Dirty API will be implemented for associations as well.
- Added better way to declare attribute inclusion/exclusion:
has_secretary on: []
andhas_secretary except: []
. This ensures that attributes will be declared before anytracks_association
are called. - Added support for singular associations tracking (has_one, belongs_to)
- Added support for Rails 4.1 (edge)
- Beta for stable 1.0 release.
- Initial release