public static void CapNhatTrangThaiPhieuMuaNL(string maPhieu) { DataAccessHelper db = new DataAccessHelper(); SqlCommand cmd = db.Command("CAP_NHAT_TRANG_THAI_PHIEU_MUA_NL"); cmd.CommandType = CommandType.StoredProcedure; cmd.Parameters.AddWithValue("@MaPhieu", maPhieu); SqlDataAdapter da = new SqlDataAdapter(cmd); db.dt = new DataTable(); da.Fill(db.dt); }
public static void XoaHoatDong(HoatDongNgoaiKhoa hoatDong) { DataAccessHelper db = new DataAccessHelper(); SqlCommand cmd = db.Command("XoaHoatDong"); cmd.CommandType = CommandType.StoredProcedure; cmd.Parameters.AddWithValue("@MaHoatDong", hoatDong.MaHoatDong); SqlDataAdapter da = new SqlDataAdapter(cmd); db.dt = new DataTable(); da.Fill(db.dt); }
public static DataTable LayDanhSachTenVaMaLop() { DataAccessHelper db = new DataAccessHelper(); SqlCommand cmd = db.Command("LAY_DANH_SACH_TEN_VA_MA_LOP"); cmd.CommandType = CommandType.StoredProcedure; SqlDataAdapter da = new SqlDataAdapter(cmd); db.dt = new DataTable(); da.Fill(db.dt); return(db.dt); }
public static DataTable LayDanhSachPhieuMuaNL() { DataAccessHelper db = new DataAccessHelper(); SqlCommand cmd = db.Command("LAY_DANH_SACH_PHIEU_MUA"); cmd.CommandType = CommandType.StoredProcedure; SqlDataAdapter da = new SqlDataAdapter(cmd); db.dt = new DataTable(); da.Fill(db.dt); return(db.dt); }
public static void XoaNV(string maNV) { DataAccessHelper db = new DataAccessHelper(); SqlCommand cmd = db.Command("XOANV"); cmd.CommandType = CommandType.StoredProcedure; cmd.Parameters.AddWithValue("@MaNV", maNV); SqlDataAdapter da = new SqlDataAdapter(cmd); db.dt = new DataTable(); da.Fill(db.dt); }
public static void XoaDichVu(DichVuSucKhoe dichVu) { DataAccessHelper db = new DataAccessHelper(); SqlCommand cmd = db.Command("XoaDichVu"); cmd.CommandType = CommandType.StoredProcedure; cmd.Parameters.AddWithValue("@MaDichVu", dichVu.MaDV); SqlDataAdapter da = new SqlDataAdapter(cmd); db.dt = new DataTable(); da.Fill(db.dt); }
public static DataTable LayDanhSachMaThucDon() { DataAccessHelper db = new DataAccessHelper(); SqlCommand cmd = db.Command("LAY_DANH_SACH_MA_THUC_DON"); cmd.CommandType = CommandType.StoredProcedure; SqlDataAdapter da = new SqlDataAdapter(cmd); db.dt = new DataTable(); da.Fill(db.dt); return(db.dt); }
public static DataTable LayDanhSachMaNguyenLieuVaSoLuongTrongMonAn(string maMonAn) { DataAccessHelper db = new DataAccessHelper(); SqlCommand cmd = db.Command("LAY_MA_NGUYEN_LIEU_VA_SO_LUONG_CAN_TU_MON_AN"); cmd.CommandType = CommandType.StoredProcedure; cmd.Parameters.AddWithValue("@MaMonAn", maMonAn); SqlDataAdapter da = new SqlDataAdapter(cmd); db.dt = new DataTable(); da.Fill(db.dt); return(db.dt); }
public static DataTable LayDanhSachMaMonAnTheoThucDon(string maThucDon) { DataAccessHelper db = new DataAccessHelper(); SqlCommand cmd = db.Command("LAY_DANH_SACH_MA_MON_AN_TRONG_THUC_DON"); cmd.CommandType = CommandType.StoredProcedure; cmd.Parameters.AddWithValue("@MaThucDon", maThucDon); SqlDataAdapter da = new SqlDataAdapter(cmd); db.dt = new DataTable(); da.Fill(db.dt); return(db.dt); }
public static void XoaDanhSachChiTietPhieuMuaNL(string maPhieuMua) { DataAccessHelper db = new DataAccessHelper(); SqlCommand cmd = db.Command("XOA_DANH_SACH_CHI_TIET_PHIEU_MUA"); cmd.CommandType = CommandType.StoredProcedure; cmd.Parameters.AddWithValue("@MaPhieu", maPhieuMua); SqlDataAdapter da = new SqlDataAdapter(cmd); db.dt = new DataTable(); da.Fill(db.dt); }
public static void XoaKetQuaHoatDong(string maHD, string maTre) { DataAccessHelper db = new DataAccessHelper(); SqlCommand cmd = db.Command("XoaKetQuaThamGiaHoatDong"); cmd.CommandType = CommandType.StoredProcedure; cmd.Parameters.AddWithValue("@MaHoatDong", maHD); cmd.Parameters.AddWithValue("@MaTre", maTre); SqlDataAdapter da = new SqlDataAdapter(cmd); db.dt = new DataTable(); da.Fill(db.dt); }
public static DataTable LayDanhSachNguyenLieu() { DataAccessHelper db = new DataAccessHelper(); SqlCommand cmd = db.Command("LAY_DANH_SACH_THONG_TIN_NGUYEN_LIEU"); cmd.CommandType = CommandType.StoredProcedure; SqlDataAdapter da = new SqlDataAdapter(cmd); db.dt = new DataTable(); da.Fill(db.dt); return(db.dt); }
public static void XoaThongTinSucKhoe(string maDV, string maTre) { DataAccessHelper db = new DataAccessHelper(); SqlCommand cmd = db.Command("XoaThongTinSucKhoe"); cmd.CommandType = CommandType.StoredProcedure; cmd.Parameters.AddWithValue("@MaDichVu", maDV); cmd.Parameters.AddWithValue("@MaTre", maTre); SqlDataAdapter da = new SqlDataAdapter(cmd); db.dt = new DataTable(); da.Fill(db.dt); }
public static void XoaPhieuMuaNL(string MaPhieuMua) { DataAccessHelper db = new DataAccessHelper(); SqlCommand cmd = db.Command("XOA_PHIEU_MUA_NGUYEN_LIEU"); cmd.CommandType = CommandType.StoredProcedure; cmd.Parameters.AddWithValue("@MaPhieu", MaPhieuMua); SqlDataAdapter da = new SqlDataAdapter(cmd); db.dt = new DataTable(); da.Fill(db.dt); }
public static void XoaLopThamGia(string maDV, string maLop) { DataAccessHelper db = new DataAccessHelper(); SqlCommand cmd = db.Command("XoaLopThamGiaDichVu"); cmd.CommandType = CommandType.StoredProcedure; cmd.Parameters.AddWithValue("@MaDichVu", maDV); cmd.Parameters.AddWithValue("@MaLop", maLop); SqlDataAdapter da = new SqlDataAdapter(cmd); db.dt = new DataTable(); da.Fill(db.dt); }
public static void CapNhatTonNguyenLieuTheoMa(string maNguyenLieu, int soLuongDung) { DataAccessHelper db = new DataAccessHelper(); SqlCommand cmd = db.Command("CAP_NHAT_SO_LUONG_NGUYEN_LIEU_THEO_MA"); cmd.CommandType = CommandType.StoredProcedure; cmd.Parameters.AddWithValue("@MaNguyenLieu", maNguyenLieu); cmd.Parameters.AddWithValue("@SoLuongDung", soLuongDung); SqlDataAdapter da = new SqlDataAdapter(cmd); db.dt = new DataTable(); da.Fill(db.dt); }
public static void ThemTreVaoLop(string maTre, string maLop) { DataAccessHelper db = new DataAccessHelper(); SqlCommand cmd = db.Command("THEMTREVAOLOP"); cmd.CommandType = CommandType.StoredProcedure; cmd.Parameters.AddWithValue("@MaTre", maTre); cmd.Parameters.AddWithValue("@MaLop", maLop); SqlDataAdapter da = new SqlDataAdapter(cmd); db.dt = new DataTable(); da.Fill(db.dt); }
public static DataTable GetListSucKhoeKoTheoLop(string maDV) { DataAccessHelper db = new DataAccessHelper(); SqlCommand cmd = db.Command("GetKetQuaKhamKoTheoLop"); cmd.CommandType = CommandType.StoredProcedure; cmd.Parameters.AddWithValue("@MaDichVu", maDV); SqlDataAdapter da = new SqlDataAdapter(cmd); db.dt = new DataTable(); da.Fill(db.dt); return(db.dt); }
public static DataTable GetThongTinNV(string maNV) { DataAccessHelper db = new DataAccessHelper(); SqlCommand cmd = db.Command("GETTHONGTINNV"); cmd.CommandType = CommandType.StoredProcedure; cmd.Parameters.AddWithValue("@MaNV", maNV); SqlDataAdapter da = new SqlDataAdapter(cmd); db.dt = new DataTable(); da.Fill(db.dt); return(db.dt); }
public static DataTable TimNV(string tuKhoa) { DataAccessHelper db = new DataAccessHelper(); SqlCommand cmd = db.Command("TIMKIEMNV"); cmd.CommandType = CommandType.StoredProcedure; cmd.Parameters.AddWithValue("@TUKHOA", tuKhoa); SqlDataAdapter da = new SqlDataAdapter(cmd); db.dt = new DataTable(); da.Fill(db.dt); return(db.dt); }
public static DataTable LayDanhSachNguyenLieu(string tuKhoa) { DataAccessHelper db = new DataAccessHelper(); SqlCommand cmd = db.Command("TIM_KIEM_NGUYEN_LIEU"); cmd.CommandType = CommandType.StoredProcedure; cmd.Parameters.AddWithValue("@TuKhoa", tuKhoa); SqlDataAdapter da = new SqlDataAdapter(cmd); db.dt = new DataTable(); da.Fill(db.dt); return(db.dt); }
public static void CapNhatMonAn(MonAn monAn) { DataAccessHelper db = new DataAccessHelper(); SqlCommand cmd = db.Command("CAP_NHAT_MON_AN"); cmd.CommandType = CommandType.StoredProcedure; cmd.Parameters.AddWithValue("@MaMonAn", monAn.MaMonAn); cmd.Parameters.AddWithValue("@TenMonAn", monAn.TenMonAn); SqlDataAdapter da = new SqlDataAdapter(cmd); db.dt = new DataTable(); da.Fill(db.dt); }
public static DataTable layDanhSachLoaiNguyenLieu() { DataAccessHelper db = new DataAccessHelper(); SqlCommand cmd = db.Command("LAY_DANH_SACH_LOAI_NGUYEN_LIEU"); cmd.CommandType = CommandType.StoredProcedure; SqlDataAdapter da = new SqlDataAdapter(cmd); db.dt = new DataTable(); da.Fill(db.dt); //DataTable dt = db.GetDataTable("SELECT * FROM NGUYENLIEU"); return(db.dt); }
public static void XoaChiTietThucDon(string maThucDon, string maMonAn) { DataAccessHelper db = new DataAccessHelper(); SqlCommand cmd = db.Command("XOA_CHI_TIET_THUC_DON"); cmd.CommandType = CommandType.StoredProcedure; cmd.Parameters.AddWithValue("@MaThucDon", maThucDon); cmd.Parameters.AddWithValue("@MaMonAn", maMonAn); SqlDataAdapter da = new SqlDataAdapter(cmd); db.dt = new DataTable(); da.Fill(db.dt); }
public static DataTable LayDanhSachApDungThucDonTheoThoiGian(DateTime NgayApDung, string Buoi) { DataAccessHelper db = new DataAccessHelper(); SqlCommand cmd = db.Command("LAY_CHI_TIET_AP_DUNG_THEO_THUC_DON"); cmd.CommandType = CommandType.StoredProcedure; cmd.Parameters.AddWithValue("@NgayApDung", NgayApDung); cmd.Parameters.AddWithValue("@Buoi", Buoi.Trim()); SqlDataAdapter da = new SqlDataAdapter(cmd); db.dt = new DataTable(); da.Fill(db.dt); return(db.dt); }
public static DataTable TreChuaCoLop(string namSinh) { DataAccessHelper db = new DataAccessHelper(); SqlCommand cmd = db.Command("TRECHUACOLOP"); cmd.CommandType = CommandType.StoredProcedure; cmd.Parameters.AddWithValue("@NamSinh", namSinh); SqlDataAdapter da = new SqlDataAdapter(cmd); db.dt = new DataTable(); da.Fill(db.dt); return(db.dt); }
public static void CapNhatTreThamGiaDichVu(string maDV, string maTre, int thamGia) { DataAccessHelper db = new DataAccessHelper(); SqlCommand cmd = db.Command("CapNhatTreThamGiaDichVu"); cmd.CommandType = CommandType.StoredProcedure; cmd.Parameters.AddWithValue("@MaDichVu", maDV); cmd.Parameters.AddWithValue("@MaTre", maTre); cmd.Parameters.AddWithValue("@ThamGia", thamGia); SqlDataAdapter da = new SqlDataAdapter(cmd); db.dt = new DataTable(); da.Fill(db.dt); }
public static void XoaNLTungMon(string maMon, string maNL) { DataAccessHelper db = new DataAccessHelper(); SqlCommand cmd = db.Command("XOA_NGUYEN_LIEU_TUNG_MON"); cmd.CommandType = CommandType.StoredProcedure; cmd.Parameters.AddWithValue("@MaMon", maMon); cmd.Parameters.AddWithValue("@MaNL", maNL); SqlDataAdapter da = new SqlDataAdapter(cmd); db.dt = new DataTable(); da.Fill(db.dt); }
public static DataTable GetHoTenTre(string maTre) { DataAccessHelper db = new DataAccessHelper(); SqlCommand cmd = db.Command("GetHoTenTre"); cmd.CommandType = CommandType.StoredProcedure; cmd.Parameters.AddWithValue("@MaTre", maTre); SqlDataAdapter da = new SqlDataAdapter(cmd); db.dt = new DataTable(); da.Fill(db.dt); return(db.dt); }
public static DataTable GetListDiemKoTheoLop(string maHD) { DataAccessHelper db = new DataAccessHelper(); SqlCommand cmd = db.Command("GetListDiemHoatDongKoTheoLop"); cmd.CommandType = CommandType.StoredProcedure; cmd.Parameters.AddWithValue("@MaHoatDong", maHD); SqlDataAdapter da = new SqlDataAdapter(cmd); db.dt = new DataTable(); da.Fill(db.dt); return(db.dt); }