public ActionResult Admin_Category()
        {
            CateDB    tool   = new CateDB();
            DataTable dtCate = tool.GetAllCate();

            return(View(dtCate));
        }
Example #2
0
        public ActionResult Staff_Category()
        {
            DataTable dtCate;

            try
            {
                CateDB tool = new CateDB();
                dtCate = tool.GetAllCate();
            }
            catch (Exception ex)
            {
                ModelState.AddModelError("", ex.Message);
                return(RedirectToAction("Error", "Error"));
            }

            return(View(dtCate));
        }