示例#1
0
 public static void UpdateStatus(fault_tbl fault)
 {
     try
     {
         using (HomeCommitteeDBEntities db = new HomeCommitteeDBEntities())
         {
             db.Entry(fault).State = System.Data.Entity.EntityState.Modified;
             db.SaveChanges();
         }
     }
     catch
     {
         throw;
     }
 }
示例#2
0
 public static void Add(fault_tbl fault)
 {
     try
     {
         using (HomeCommitteeDBEntities db = new HomeCommitteeDBEntities())
         {
             db.fault_tbl.Add(fault);
             db.SaveChanges();
         }
     }
     catch
     {
         throw;
     }
 }