Example #1
0
        public User AddNewUser(User user)
        {
            User newUser = _dbContext.GetUsers().Add(user);

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