Frequently Used Methods
Frequently Used Methods
Frequently Used Methods
Frequently Used Methods
public IEnumerable <CommentViewModel> GetAllComment() { IEnumerable <CommentDTO> commentDTOs = travelService.GetAllCommentList(); Mapper.Initialize(cfg => cfg.CreateMap <CommentDTO, CommentViewModel>()); var comments = Mapper.Map <IEnumerable <CommentDTO>, List <CommentViewModel> >(commentDTOs); return(comments); }