private void ReplyToProductComment(ProductComment productComment, IProductCommentCommand command) { var comment = _productCommentRepository.GetById(command.CommentId); productComment.ParentId = command.CommentId; AssigneCommentToProduct(comment, command); }
private void AssigneCommentToProduct(ProductComment comment, IProductCommentCommand command) { var product = _productRepository.GetProductDetailById(command.ProductId); comment.Products.Add(product); }
private void AddProductComment(ProductComment comment, IProductCommentCommand command) { comment.Body = command.Body; comment.UserId = command.UserId; AssigneCommentToProduct(comment, command); }