public HttpResponseMessage List() { HttpResponseMessage response = null; try { response = Request.CreateResponse(HttpStatusCode.OK, educationService.GetAllEducation()); } catch (Exception ex) { response = Request.CreateResponse(HttpStatusCode.InternalServerError, ex.Message); } return(response); }
public IActionResult Index() { var list = _educationService.GetAllEducation(); return(View(list)); }