Beispiel #1
0
 private void PrepareQuizCommentModel(QuizCommentModel model, QuizComment comment)
 {
     model.CommentId  = comment.CommentId;
     model.CreatedUtc = comment.CreatedUtc;
     model.Comment    = comment.Comment;
     model.QuizId     = comment.QuizId;
 }
Beispiel #2
0
        public void CreateComment(int quizId, string comment)
        {
            var quizComment = new QuizComment
            {
                QuizId     = quizId,
                CreatedUtc = DateTime.UtcNow,
                Comment    = comment
            };

            _quizCommentRepository.Insert(quizComment);
        }