Example #1
0
        public QuizzGame Create(QuizzGame item)
        {
            if (item == null)
            {
                throw new InvalidOperationException("QuizzGame item is null");
            }

            _context.Games.Add(new DAO.Quizz.GameDAO()
            {
                StartDate = item.StartTime,
                EndDate   = item.EndTime,
                Score     = item.Score
            });

            if (_context.SaveChanges() > 0)
            {
                return(item);
            }
            else
            {
                return(null);
            }
        }
Example #2
0
 public QuizzGame Update(Guid id, QuizzGame item)
 {
     throw new NotImplementedException();
 }