Adding view function to delete tasks