made the gui work with DAO, modified a few things in the gui and added some test cases