public void Delete(int id) { TaxZone taxZone = Find(id); var taxRates = taxRateService.FindByZone(id).ToList(); foreach (var taxRate in taxRates) { taxRateService.Delete(taxRate.Id); } db.TaxZones.Remove(taxZone); db.SaveChanges(); }