Make history class

This adds the SampleHistory Class to entities.py.
The history generation is slightly faster than the previous version, but not by much (~10%).

Another PR will come for the scilifelab repo to use this object rather than the methods from lims_utils.py.
Yeah but I think that helps understanding what is happening. If I use just one elif, it looks like I am testing three completely different things. I'll do it in the next commit, so you can see whichever you prefer.