Add functions add, edit for user