public LessonEditViewModel Update(LessonEditViewModel LessonEditViewModel) { Lesson Lesson = LessonRepo.Update(LessonEditViewModel.ToModel()); unitOfWork.commit(); return(Lesson.ToEditableViewModel()); }
public ActionResult Update(LessonEditViewModel Lesson) { if (!ModelState.IsValid) { return(View()); } LessonService.Update(Lesson); return(RedirectToAction("Lesson")); }