Refactored date from double to DateTime.
Add add and edit.
Added error handling.