public bool Update(TEntity entity) { try { _db.Entry(entity).State = EntityState.Modified; return(true); } catch { return(false); } }
public bool DeleteUser(Users user) { try { db.Entry(user).State = EntityState.Deleted; return(true); } catch { return(false); } }