Exemple #1
0
        public async Task <IActionResult> GetComments(int ticketId, [FromQuery] CommentParams commentParams)
        {
            var commentsFromRepo = await _repo.GetComments(ticketId, commentParams);

            var comments = _mapper.Map <IEnumerable <CommentsToReturn> >(commentsFromRepo);

            return(Ok(new { comments, commentParams.Length }));
        }