public ActionResult GetCommentList(CommentRequest page) { int recordCount = 0; var list = new ProductCommentService().GetCommentList(page.ProductId, page.PageIndex, page.PageSize, out recordCount); int count = SysHelper.GetPageCount(recordCount, page.PageSize); var data = new PageReturnEntity <List <CommentInfoEntity> > { PageCount = count, Data = list }; return(JsonCResult(data)); }
public ActionResult GetSearchList(SearchRequest req) { int recordCount = 0; var list = new BookService().GetBookList(req.CategorId, req.Key, req.PageIndex, req.PageSize, out recordCount); int count = SysHelper.GetPageCount(recordCount, req.PageSize); var data = new PageReturnEntity <List <BookInfoEntity> > { PageCount = count, Data = list }; return(JsonCResult(data)); }