public bool Insert(ChequeBank chequeBank) { try { _chequeBanks.Add(chequeBank); return(true); } catch (Exception) { return(false); } }
public bool Delete(ChequeBank chequeBank) { try { _chequeBanks.Attach(chequeBank); _chequeBanks.Remove(chequeBank); return(true); } catch (Exception) { return(false); } }
public bool Update(ChequeBank chequeBank) { try { _chequeBanks.Attach(chequeBank); _uow.Entry(chequeBank).State = EntityState.Modified; //_uow.Entry(chequeBank).Property(p => p.CreatedOn).IsModified = false; //_uow.Entry(chequeBank).Property(p => p.CreatedBy).IsModified = false; return(true); } catch (Exception) { return(false); } }