Updated function names, added create, update and delete behaviors to model.