Exemple #1
0
        public PartialViewResult Category()
        {
            var dao = new LoaiHangDao();
            var ls  = dao.GetAll();

            return(PartialView("_Category", ls));
        }
Exemple #2
0
        public void SetViewBag(int?selectedId = null)
        {
            var dao = new LoaiHangDao();

            ViewBag.MaLoaiHang = new SelectList(dao.GetAll(), "ma", "loai", selectedId);
        }