Skip to content

Latest commit

 

History

History
55 lines (45 loc) · 2.39 KB

HISTORY.md

File metadata and controls

55 lines (45 loc) · 2.39 KB

Vitamin changes log

v0.8.4 - December 20, 2016

  • Remove vitamin-query dependency
  • Update the Collection API (add search, promise and other methods)

v0.8.3 - September 27, 2016

  • Add the belongs-to-many relationship toggle method
  • Update README.md
  • Fix some bugs

v0.8-0 - Septempber 4, 2016

This is a breaking changes version, Vitamin become a Data Mapper implementation instead of the Active Record. So the mapping logic was moved to the Mapper class

  • Export the BaseModel, BaseQuery and Events to separate projects
  • Wrote in ES6 style and use babeljs as compiler
  • Add the polymorphic relationships
  • Add models registry
  • Provide a new API

v0.7.5 - June 26, 2016

  • Add Attribute accessors and mutators feature
  • Add query method paginate() for simple pagination
  • Add query method value() to get a value of a single column
  • Add increment() and decrement() model methods
  • Change connection() to return the current DB connection if no parameter passed in

v0.7.4 - June 23, 2016

  • Add pluck(), count(), sum(), min(), max() and avg() query methods
  • Add sync() method to enhance many-to-many associations

v0.7.3 - June 19, 2016

  • Fix: model.get() which returns undefined for falsy values
  • Fix: attach() and detach() to accept also model collections
  • Add findMany, findOrNew, firstOrNew, firstOrCreate Query helpers
  • Add a new life-cycle event: ready to add more initialization logic
  • model.fetch() accept an array of relations, as first argument, to fetch with

v0.7.2 - June 15, 2016

  • Fix: for eager loading, for no parent models, we resolve without loading relationships (Performance)
  • Add newExistingInstance() helper method in model class
  • Add default attributes hash to init the model's data
  • Add protection against mass assignment
  • Add the ability to blacklist attributes from toJSON()
  • Add collections to be used instead of arrays for relations

v0.7.1 - June 12, 2016

  • Rename many-to-many joining table as pivot for fluent querying
  • Fix: load() to resolve with the current model
  • Fix: getOriginal() to return a copy of the original hash
  • Add default message for custom errors
  • Add relationship methods: create(), createMany(), save(), saveMany() and updatePivot()

v0.7.0 - June 10, 2016

  • First release as an Active Record library