예제 #1
0
        public ActionResult BillPartial(DateTime?dateTime, int currentPage = 1, int pageSize = 20)
        {
            var bills = billDAO.GetAllBill(dateTime, currentPage, pageSize);

            ViewBag.PageNumber = Paginate.GetTotalPage(bills.TotalCount, pageSize);
            return(PartialView(bills.Items));
        }
        public ActionResult UserPartial(string search, int currentPage = 1, int pageSize = 10)
        {
            var accounts = userDAO.GetAllUsersByKeyWord(search, currentPage, pageSize);

            ViewBag.PageNumber = Paginate.GetTotalPage(accounts.TotalCount, pageSize);
            return(PartialView(accounts.Items));
        }
예제 #3
0
        public ActionResult ProducerPartial(string search, int currentPage = 1, int pageSize = 20)
        {
            var produces = producerDAO.GetAllProducerByKeyWord(search, currentPage, pageSize);

            ViewBag.PageNumber = Paginate.GetTotalPage(produces.TotalCount, pageSize);
            return(PartialView(produces.Items));
        }
        public async Task <ActionResult> CategoryPartial(long id, int currentPage = 1, int pageSize = 9)
        {
            var products = await productDAO.GetAllProductByCategory(id, pageSize, currentPage);

            ViewBag.PageNumber = Paginate.GetTotalPage(products.TotalCount, pageSize);
            return(PartialView(products.Items));
        }
        public ActionResult CategoryPartial(string search, int currentPage = 1, int pageSize = 20)
        {
            var categories = categoryDAO.GetAllCategoryByKeyWord(search, currentPage, pageSize);

            ViewBag.PageNumber = Paginate.GetTotalPage(categories.TotalCount, pageSize);
            return(PartialView(categories.Items));
        }
예제 #6
0
        public ActionResult Index(string search, int currentPage = 1, int pageSize = 10)
        {
            var products = productDAO.GetAllProductByKeyWord(search, currentPage, pageSize);

            ViewBag.PageNumber = Paginate.GetTotalPage(products.TotalCount, pageSize);
            return(View(products.Items));
        }