public async Task <IActionResult> ShowComment([FromBody] GetCommentInputDto getinput) { if (!ModelState.IsValid) { return(BadRequest()); } var result = await CommentServise.GetComment(getinput); return(Ok(result)); }
public async Task <GetCoomentOutputDto> GetComment(GetCommentInputDto getinput) { var findcomment = await FindComment(getinput.CommentId); findcomment = CommentRepository.GetQuery() .Include(c => c.TuristPlace) .Include(c => c.User) .FirstOrDefault(c => c.Id == findcomment.Id); return(mapper.Map <GetCoomentOutputDto>(findcomment)); }