Make persistence drastically dumber and simpler

Instead of denormalizing things and worrying about fetching
relationships, just store the whole structure of the dataset in IDB and
keep it in memory when on the site.

Sorry, I finally had enough of trying to deal with relationships in
IndexedDB. Hopefully someday they'll get better with indexing so that
it's possible to make functional/arbitrary indexes or something.
Split Backbone.sync out into its own module
Centralize fns for updating db & implement patch history

There is only one copy of the data tree stored now, in the `localData`
objectStore. To update it, one must call db.updateLocalData with the new
data and an optional message. When using that function, not only will
the data be replaced, but forward and backward patches will be stored
enabling a version history and potentially undo/redo functionality.
Make JSON serializations of models match data model
Merge pull request #4 from periodo/simpler-persistence

Simpler persistence

De-denormalize database representation of data. Instead, store entire data structure in IDB and then in memory when using the site.