bilal-fazlani / tracker-enabled-dbcontext

Tracker-enabled DbContext offers you to implement full auditing in your database
https://tracker-enabled-dbcontext.bilal-fazlani.com/
Other
217 stars 110 forks source link

Allow tracking to be disabled per instance of dbcontext #139

Closed mgildea closed 7 years ago

mgildea commented 7 years ago

added context specific tracking enabled indicator in ITrackerContext and utilized GlobalTrackingConfig.Enabled and local tracking enabled property in SaveChanges methods when determining if tracking is enabled. Included unit test for TrackerContext and TrackerIdentityContext.

This allows a user to turn on/off db tracking in the middle of a single dbcontext instance.

We had discussed this functionality in the past but I did not come around to implementing until now.