AjaxExamples.Controllers.SessionsController.Index C# (CSharp) Метод

Index() публичный Метод

public Index ( ) : System.Web.Mvc.ActionResult
Результат System.Web.Mvc.ActionResult
        public ActionResult Index()
        {
            var sessions = _repository.FindAll();

            //for ajax requests, we simply need to render the partial
            if(Request.IsAjaxRequest())
                return View("_sessionList", sessions);

            return View(sessions);
        }