Added database interaction and populated home view