public async Task <TrainerRate> UpdateTrainerRate(TrainerRate rate) { _trainingPlannerDbContext.Update(rate); await _trainingPlannerDbContext.SaveChangesAsync(); return(rate); }
public async Task <TrainerRate> CreateTrainerRate(TrainerRate rate) { await _trainingPlannerDbContext.TrainerRatings.AddAsync(rate); await _trainingPlannerDbContext.SaveChangesAsync(); return(rate); }
public async Task DeleteTrainerRate(TrainerRate rate) { _trainingPlannerDbContext.TrainerRatings.Remove(rate); await _trainingPlannerDbContext.SaveChangesAsync(); }