예제 #1
0
파일: TheLoaiBUS.cs 프로젝트: viethuy20/git
 public static bool SuaTheLoai(TheLoaiDTO tl)
 {
     if (TheLoaiDAO.GetTheLoaiByMa(tl.MaTheLoai) != null)
     {
         TheLoaiDAO.Update(tl);
         return(true);
     }
     else
     {
         return(false);
     }
 }
예제 #2
0
파일: TheLoaiBUS.cs 프로젝트: viethuy20/git
 public static bool ThemTheLoai(TheLoaiDTO tl)
 {
     if (TheLoaiDAO.GetTheLoaiByName(tl.TenTheLoai) == null)
     {
         TheLoaiDAO.Insert(tl);
         return(true);
     }
     else
     {
         return(false);
     }
 }
예제 #3
0
파일: TheLoaiBUS.cs 프로젝트: viethuy20/git
 public static bool XoaTheLoai(TheLoaiDTO tl)
 {
     if (TheLoaiDAO.GetTheLoaiByName(tl.TenTheLoai) != null)
     {
         TheLoaiDAO.Delete(tl);
         return(true);
     }
     else
     {
         return(false);
     }
 }