Connected Tasks to the database. Added more functionality to Tasks