Esempio n. 1
0
        //
        // GET: /Loai/Create
        public ActionResult Create()
        {
            ChungLoaiViewModel cl = new ChungLoaiViewModel();

            cl.dsCLoai = ChungLoaiBus.DanhSach();
            return(View(cl));
        }
Esempio n. 2
0
 public ActionResult Delete(int id, ChungLoai cl)
 {
     try
     {
         // TODO: Add delete logic here
         ChungLoaiBus.Xoa(id, cl);
         return(RedirectToAction("Index"));
     }
     catch
     {
         return(View());
     }
 }
Esempio n. 3
0
 public ActionResult Edit(int id, ChungLoai cl)
 {
     try
     {
         // TODO: Add update logic here
         ChungLoaiBus.Sua(id, cl);
         return(RedirectToAction("Index"));
     }
     catch
     {
         return(View());
     }
 }
Esempio n. 4
0
 public ActionResult Create(ChungLoai cl)
 {
     try
     {
         // TODO: Add insert logic here
         ChungLoaiBus.Them(cl);
         return(RedirectToAction("Index"));
     }
     catch
     {
         return(View());
     }
 }
Esempio n. 5
0
        //

        public ActionResult Delete(int id)
        {
            return(View(ChungLoaiBus.ChiTiet(id)));
        }
Esempio n. 6
0
 public ActionResult Topbar()
 {
     return(PartialView("_Topbar", ChungLoaiBus.DanhSach()));
 }
Esempio n. 7
0
        //

        public ActionResult Index()
        {
            return(View(ChungLoaiBus.DanhSach()));
        }