public void Add(Training training) { var jsonTraining = JsonConvert.SerializeObject(training); WriteToFile(jsonTraining); }
public ViewTrainingsForm(string mode) : this() { this.mode = mode; SelectedTraining = new Training(); }
public void UpdateTraining(Training training) { var trainingDb = ToTrainingDb(training); repository.Update(trainingDb); }
public void DeleteTraining(Training training) { var trainingDb = ToTrainingDb(training); repository.Delete(trainingDb); }
public void AddTraining(Training training) { var trainingDb = ToTrainingDb(training); repository.Add(trainingDb); }
public TrainingForm(Training training) : this() { this.training = training; FillFormControls(); }