public bool DeleteQuizInTheard(int id) { var tan = tn.ch_db.Find(id); tn.ch_db.Remove(tan); tn.SaveChanges(); return(true); }
public bool Delete(int id) { var qz = tn.KetQuas.Find(id); tn.KetQuas.Remove(qz); tn.SaveChanges(); return(true); }
public int Insert(DeThi entity) { tn.DeThis.Add(entity); tn.SaveChanges(); return(entity.MaDe); }
public int Insert(ThiSinh entity) { tn.ThiSinhs.Add(entity); tn.SaveChanges(); return(entity.MaThiSinh); }
public int Insert(Quiz entity) { tn.Quizs.Add(entity); tn.SaveChanges(); return(entity.MaCauHoi); }
public int Insert(MonThi entity) { tn.MonThis.Add(entity); tn.SaveChanges(); return(entity.MaMon); }
public int Insert(Lop entity) { tn.Lops.Add(entity); tn.SaveChanges(); return(entity.MaLop); }
public int Insert(TaiKhoan entity) { tn.TaiKhoans.Add(entity); tn.SaveChanges(); return(entity.id); }