public bool AddExportBill_Detail(export_bill_detail eb) { try { using (QLBH_PHONE_ENTITY data = new QLBH_PHONE_ENTITY()) { data.export_bill_detail.Add(eb); data.SaveChanges(); return(true); } } catch (Exception e) { Debug.WriteLine(e); return(false); } }
public bool UpdateExportBill_Detail(export_bill_detail eb) { try { using (QLBH_PHONE_ENTITY data = new QLBH_PHONE_ENTITY()) { data.Entry(eb).State = EntityState.Modified; data.SaveChanges(); return(true); } } catch (Exception e) { Debug.WriteLine(e); return(false); } }