public IActionResult Create(BaiHocDTO baiHocDTO)
 {
     if (ModelState.IsValid)
     {
         baiHocDTO.Id = 0;
         baiHocService.Create(baiHocDTO);
         return(RedirectToAction("CreateChiTietBaiHoc"));
     }
     return(View(baiHocDTO));
 }
Exemplo n.º 2
0
 public IActionResult EditBaiHocConfirm(BaiHocDTO baiHoc)
 {
     if (ModelState.IsValid)
     {
         baiHocService.Create(baiHoc);
         ChuDeDTO chuDe = chuDeService.GetChuDe(baiHoc.IdchuDe);
         return(RedirectToAction("Details", chuDe));
     }
     return(View(baiHoc));
 }