示例#1
0
        /// <summary>
        /// 浏览商品列表
        /// </summary>
        public ActionResult AjaxBrowseProductList()
        {
            int page = WebHelper.GetQueryInt("page");//当前页数

            PageModel pageModel = new PageModel(10, page, BrowseHistories.GetUserBrowseProductCount(WorkContext.Uid));
            AjaxBrowseProductListModel model = new AjaxBrowseProductListModel()
            {
                ProductList = BrowseHistories.GetUserBrowseProductList(pageModel.PageSize, pageModel.PageNumber, WorkContext.Uid),
                PageModel   = pageModel
            };

            return(Json(model, JsonRequestBehavior.AllowGet));
        }
示例#2
0
        /// <summary>
        /// 浏览商品列表
        /// </summary>
        public ActionResult AjaxBrowseProductList()
        {
            int page = WebHelper.GetQueryInt("page");//当前页数

            PageModel pageModel = new PageModel(10, page, BrowseHistories.GetUserBrowseProductCount(WorkContext.Uid));
            AjaxBrowseProductListModel model = new AjaxBrowseProductListModel()
            {
                ProductList = BrowseHistories.GetUserBrowseProductList(pageModel.PageSize, pageModel.PageNumber, WorkContext.Uid),
                PageModel   = pageModel
            };

            return(Content(JsonConvert.SerializeObject(model)));
        }