Example #1
0
 public bool insertChiTiet(THAMDUDAIHOI data)
 {
     try
     {
         using (QLHTDOANVIENDataContext db = new QLHTDOANVIENDataContext())
         {
             db.THAMDUDAIHOIs.InsertOnSubmit(data);
             db.SubmitChanges();
             return(true);
         }
     }
     catch (Exception e)
     {
         Console.WriteLine(e.Message.ToString());
     }
     return(false);
 }
Example #2
0
        public bool setStatus(Guid idDV, Guid idDH)
        {
            THAMDUDAIHOI data = new THAMDUDAIHOI();

            try
            {
                using (QLHTDOANVIENDataContext db = new QLHTDOANVIENDataContext())
                {
                    data = db.THAMDUDAIHOIs.Where(p => p.MASODH == idDH && p.MASODV == idDV).SingleOrDefault();
                    if (data != null)
                    {
                        data.TRANGTHAI = true;
                        db.SubmitChanges();
                        return(true);
                    }
                }
            }
            catch (Exception)
            {
            }
            return(false);
        }
Example #3
0
 private void detach_THAMDUDAIHOIs(THAMDUDAIHOI entity)
 {
     this.SendPropertyChanging();
     entity.DOANVIEN = null;
 }
Example #4
0
 partial void DeleteTHAMDUDAIHOI(THAMDUDAIHOI instance);
Example #5
0
 partial void UpdateTHAMDUDAIHOI(THAMDUDAIHOI instance);
Example #6
0
 partial void InsertTHAMDUDAIHOI(THAMDUDAIHOI instance);
Example #7
0
 private void attach_THAMDUDAIHOIs(THAMDUDAIHOI entity)
 {
     this.SendPropertyChanging();
     entity.DAIHOI = this;
 }