public IActionResult AddLesson(ApiSettings apiSettings) { VMLesson lesson = ConvertJson.Deserialize <VMLesson>(apiSettings.Obj.ToString()); _lessonService.AddLesson(lesson); return(Ok("Success")); }
public async Task <bool> AddLesson(VMLesson lesson) { var les = _mapper.Map <Lesson>(lesson); await _lessonService.AddAsync(les); return(true); }