Пример #1
0
        public ActionResult DeleteOrder(int id)
        {
            Category category = new Category();

            ViewBag.Category = category.GetCategories();

            AdminOrder adminOrder = new AdminOrder();

            adminOrder.DeleteOrder(id);

            var data = adminOrder.GetOrders();

            return(PartialView(data));
        }
Пример #2
0
        // GET: AdminOrders
        public ActionResult Index(int?page)
        {
            Category category = new Category();

            ViewBag.Category = category.GetCategories();

            AdminOrder adminOrder = new AdminOrder();
            var        data       = adminOrder.GetOrders();

            int pageSize   = 10;
            int pageNumber = (page ?? 1);

            return(View(data.ToPagedList(pageNumber, pageSize)));
        }