Пример #1
0
 public static int DeleteNhanVien(NhanVienObjTr ctd)
 {
     SqlParameter[] para = new SqlParameter[]
     {
         new SqlParameter("@manv", ctd.maNV)
     };
     return(ConnetctToSQLTr.ExecuteNonQuery("XoaNhanVien", para));
 }
Пример #2
0
 public static int UpdateNhanVien(NhanVienObjTr ctd)
 {
     SqlParameter[] para = new SqlParameter[]
     {
         new SqlParameter("@manv", ctd.maNV),
         new SqlParameter("@hoten", ctd.HoTen),
         new SqlParameter("@ngaysinh", ctd.NgaySinh),
         new SqlParameter("@gioitinh", ctd.GioiTinh),
         new SqlParameter("@socmnd", ctd.SoCMND),
         new SqlParameter("@sdt", ctd.SDT),
         new SqlParameter("@macv", ctd.MaCV),
         new SqlParameter("@mapb", ctd.MaPB),
         new SqlParameter("@mahd", ctd.MaHD)
     };
     return(ConnetctToSQLTr.ExecuteNonQuery("SuaNhanVien", para));
 }
Пример #3
0
 public static DataTable GetListHopDong()
 {
     return(ConnetctToSQLTr.GetData("select *  from HopDong"));
 }
Пример #4
0
 public static DataTable GetListChuVu()
 {
     return(ConnetctToSQLTr.GetData("select *  from ChucVu"));
 }
Пример #5
0
 public static DataTable GetListNhanVien()
 {
     return(ConnetctToSQLTr.GetData("select NhanVien.MaNV, HoTen,NgaySinh,GioiTinh,SoCMND,NhanVien.SDT,TenCV,TenPB,TenHD  from NhanVien,PhongBan,ChucVu,HopDong where NhanVien.MaCV=ChucVu.MaCV and  NhanVien.MaPB=PhongBan.MaPB and NhanVien.MaHD=HopDong.MaHD"));
 }
Пример #6
0
 public static DataTable GetListPhongBan()
 {
     return(ConnetctToSQLTr.GetData("select *  from PhongBan"));
 }