예제 #1
0
        public async Task <ActionResult> GetTopicComment(int id, int commentId)
        {
            var comment = await _repo.GetCircleTopicComment(commentId);

            var topicsCommentForReturn = this._mapper.Map <CircleTopicCommentForReturnDto>(comment);

            topicsCommentForReturn.ReplyCount = await _repo.GetCircleTopicCommentReplyCount(comment.Id);

            return(Ok(topicsCommentForReturn));
        }
        public async Task <ActionResult> Get(int id)
        {
            var circleTopicCommentForReturn = _mapper.Map <CircleTopicCommentForReturnDto>(await _repo.GetCircleTopicComment(id));

            circleTopicCommentForReturn.ReplyCount = await _repo.GetCircleTopicCommentReplyCount(id);

            return(Ok(circleTopicCommentForReturn));
        }