public User AddNewUser(User user) { User newUser = _dbContext.GetUsers().Add(user); _dbContext.Save(); return(newUser); }
public void UploadLogo(Photo photo) { _dbContext.GetUsers().Where(u => u.ID == photo.UserID).First().Photos.Add(photo); _dbContext.Save(); }
public void ChangePasswordByID(int userId, string newPassword) { _dbContext.GetUsers().Where(u => u.ID == userId).First().Password = newPassword; _dbContext.Save(); }