This library tracks historical changes for any document, including embedded ones. It achieves this by storing all history tracks in a single collection that you define. Embedded documents are referenced by storing an association path, which is an array of document_name and document_id fields starting from the top most parent document and down to the embedded document that should track history. Mongoid-history implements multi-user undo, which allows users to undo any history change in any order. Undoing a document also creates a new history track. This is great for auditing and preventing vandalism, but it is probably not suitable for use cases such as a wiki.

installgem install mongoid-history

Aaron Qian, Justin Grimes, Daniel Doubrovkine

70,696 total downloads 3,004 for this version




gem 'mongoid-history', '~> 0.4.1'
  1. 0.4.1 January 11, 2014 (23.5 KB)
  2. 0.4.0 July 12, 2013 (22 KB)
  3. 0.3.3 April 1, 2013 (17.5 KB)
  4. 0.3.2 January 24, 2013 (16.5 KB)
  5. 0.3.1 November 16, 2012 (16 KB)
Show all versions (30 total)