Exemplo n.º 1
0
        public void ActionIndex(MAlbumDetailModel model)
        {
            var dbQuery = ModAlbumDetailService.Instance.CreateQuery()
                          .Where(o => o.Activity == true)
                          .OrderByDesc(o => o.ID)
                          .Take(PageSize)
                          .Skip(PageSize * model.Page);

            ViewBag.Data      = dbQuery.ToList();
            model.TotalRecord = dbQuery.TotalRecord;
            model.PageSize    = PageSize;
            ViewBag.Model     = model;
        }
        public void ActionIndex(MAlbumDetailModel model)
        {
            var dbQuery = ModAlbumDetailService.Instance.CreateQuery()
                            .Where(o => o.Activity == true)
                            .OrderByDesc(o => o.ID)
                            .Take(PageSize)
                            .Skip(PageSize * model.Page);

            ViewBag.Data = dbQuery.ToList();
            model.TotalRecord = dbQuery.TotalRecord;
            model.PageSize = PageSize;
            ViewBag.Model = model;
        }