// GET: Category
        public ActionResult Index(string searchValue = "")
        {
            var model = new Models.CategoryResult()
            {
                RowCount    = CatalogBLL.Category_Count(searchValue),
                Data        = CatalogBLL.Category_List(searchValue),
                SearchValue = searchValue
            };

            return(View(model));
        }
Пример #2
0
        /// <summary>
        ///
        /// </summary>
        /// <returns></returns>
        public ActionResult Index(string searchValue = "")
        {
            var model = new Models.CategoryResult
            {
                RowCount = CatalogBLL.Category_Count(searchValue),
                Data     = CatalogBLL.Category_List(searchValue),
            };

            //var listOfSuppliers = CatalogBLL.Supplier_List(page, 10, searchValue);
            //int rowCount = CatalogBLL.Supplier_Count(searchValue);
            //ViewBag.rc = rowCount;
            return(View(model));
        }
Пример #3
0
        // GET: Category
        /// <summary>
        /// Trang hiển thị danh sách các Category
        /// </summary>
        /// <param name="page"></param>
        /// <param name="searchValue"></param>
        /// <returns></returns>
        public ActionResult Index(int page = 1, string searchValue = "")
        {
            int pageSize = 999999;
            var model    = new Models.CategoryResult()
            {
                Page        = page,
                PageSize    = pageSize,
                RowCount    = CatalogBLL.Category_Count(searchValue),
                Data        = CatalogBLL.Category_List(page, pageSize, searchValue),
                searchValue = searchValue,
            };

            return(View(model));
        }