Example #1
0
        public ActionResult Activate(int id)
        {
            var course = _courseService.GetCourse(id);

            _courseService.ActivateCourse(id);
            return(RedirectToAction("Index"));
        }
Example #2
0
 public async Task <IActionResult> ActivateCourse(int courseId)
 {
     return(Ok(await _courseService.ActivateCourse(courseId)));
 }
Example #3
0
        public async Task <IActionResult> ActivateCourse([FromQuery] int id, [FromQuery] int index)
        {
            await _courseService.ActivateCourse(id, index);

            return(Ok());
        }