public ActionResult Detail(int?id) { var result = new UserPdtCommentDetail(); result.IntCommentID = id; result = UserPdtCommentClient.Instance.QueryUserPdtCommentById(result); #region 获取评论信息下面的所有回复信息 var req = new UserPdtCommentCusReplyRefer(); req.SearchDetail.CommentId = id.Value; var resComment = UserPdtCommentClient.Instance.QueryUserPdtCommentCusReply(req); ViewBag.CommentCusReply = resComment; #endregion return(View(result)); }
/// <summary> /// 获取评论信息下面的所有回复信息 /// </summary> /// <param name="commentDetail"></param> /// <returns></returns> public UserPdtCommentCusReplyRefer QueryUserPdtCommentCusReply(UserPdtCommentCusReplyRefer CommentReply) { var result = new UserPdtCommentCusReplyRefer(); var req = new QueryUserPdtCommentCusReplyRequest(); if (CommentReply.SearchDetail != null) { req.CommentId = CommentReply.SearchDetail.CommentId; } req.PageIndex = CommentReply.PageIndex ?? 0; req.PageSize = CommentReply.PageSize ?? 0; var res = OpcClient.Send <QueryUserPdtCommentCusReplyResponse>(req); if (res.DoFlag) { result.List = Mapper.MappGereric <User_Pdt_Comment_CusReplyExt, UserPdtCommentCusReplyDetail>(res.CommentCusReplyDos); result.Total = res.Total; } result.SearchDetail = CommentReply.SearchDetail; result.PageIndex = CommentReply.PageIndex; result.PageSize = CommentReply.PageSize; return(result); }