database to firebase and add list function