예제 #1
0
 public void Update(DS_Turnover Turnover)
 {
     using (var ct = new DS_TurnoverDataContext(DbHelperSQL.Connection))
     {
         ct.DS_Turnover.Attach(Turnover, true);
         ct.SubmitChanges();
     }
 }
예제 #2
0
 public void Add(DS_Turnover Turnover)
 {
     using (var ct = new DS_TurnoverDataContext(DbHelperSQL.Connection))
     {
         ct.DS_Turnover.InsertOnSubmit(Turnover);
         ct.SubmitChanges();
     }
 }
예제 #3
0
 public void Delete(int ID)
 {
     using (var ct = new DS_TurnoverDataContext(DbHelperSQL.Connection))
     {
         DS_Turnover st = ct.DS_Turnover.Single(a => a.ID == ID);
         ct.DS_Turnover.DeleteOnSubmit(st);
         ct.SubmitChanges();
     }
 }