Esempio n. 1
0
 public virtual void Remove(KB_LCTT_GT user)
 {
     try
     {
         db.KB_LCTT_GTs.DeleteOnSubmit(user);
         db.SubmitChanges();
     }
     catch (Exception e)
     {
         throw new Exception(e.Message);
     }
 }
Esempio n. 2
0
 public virtual void Create(KB_LCTT_GT user)
 {
     try
     {
         this.db.KB_LCTT_GTs.InsertOnSubmit(user);
         db.SubmitChanges();
     }
     catch (Exception e)
     {
         throw new Exception(e.Message);
     }
 }
Esempio n. 3
0
 public virtual void Update(KB_LCTT_GT user)
 {
     try
     {
         KB_LCTT_GT userOld = this.GetById(user.CHI_TIEU);
         userOld = user;
         db.SubmitChanges();
     }
     catch (Exception e)
     {
         throw new Exception(e.Message);
     }
 }
Esempio n. 4
0
 public virtual int Delete(KB_LCTT_GT user)
 {
     try
     {
         //user.IsDelete = true;
         db.SubmitChanges();
         return 0;
     }
     catch (Exception e)
     {
         throw new Exception(e.Message);
     }
 }