Ejemplo n.º 1
0
 /// <summary>
 /// The delete treatment.
 /// </summary>
 /// <param name="treatment">
 /// The treatment.
 /// </param>
 private void DeleteTreatment(TreatmentModel treatment)
 {
     using (var api = new BusinessContext())
     {
         try
         {
             var tmpTreatment = api.GetAllTreatmentsById(treatment.Id);
             api.DeleteTreatment(tmpTreatment);
         }
         catch (Exception)
         {
         }
         this.TreatmentTypes.Remove(treatment);
     }
 }