コード例 #1
0
ファイル: HomeController.cs プロジェクト: ABartles/CSHP_230_D
        //---- Enroll ----

        public ActionResult Enroll()
        {
            var classes = classManager.ClassList()
                          .Select(t => new LearningCenter.WebSite.Models.ClassModel
            {
                Id          = t.Id,
                Name        = t.Name,
                Description = t.Description,
                Price       = t.Price
            }).ToArray();

            var model = new ClassViewModel
            {
                Classes = classes
            };

            return(View(model));
        }
コード例 #2
0
        public ActionResult ClassList()
        {
            var classList = classManager.ClassList();

            return(View(classList));
        }