Adding the logging feature
More changes.  Need to fix integration tests and add quantity to the history table