示例#1
0
        public IEnumerable <SanPham> LayTatCaPhanTrang(int page, int pageSize, out int totalRow)
        {
            var query = _sanPhamRepository.GetMulti(x => x.DaXoa == false);

            totalRow = query.Count();
            return(query.Skip((page - 1) * pageSize).Take(pageSize));
        }
示例#2
0
 public IEnumerable <SanPham> GetAllByIdShop(int id)
 {
     return(_sanPhamRepository.GetMulti(x => x.IdShop == id, new string[] { }).OrderByDescending(y => y.NgayNhap));
 }