Implemented saving of enter and leaving times