refactoring datescontroller
cleaned up tests - All passing