basic check on login time and refactored model with date not datetime