示例#1
0
        public StudyPlan Update(StudyPlan studyPlan)
        {
            var existentStudyPlan = _studyPlanRepository.Get(studyPlan.Id);

            if (existentStudyPlan == null)
            {
                throw new Exception("There is no Study Plan with that ID");
            }

            var updatedValue = _studyPlanRepository.Update(studyPlan);

            return(updatedValue);
        }
 public async Task Update(StudyPlan studyPlan)
 {
     await _studyPlanRepository.Update(studyPlan);
 }