Exemplo n.º 1
0
        // GET: Wap/Home
        public ActionResult Index()
        {
            HomeViewModel wm = new HomeViewModel();

            wm.banners     = _bannerAppService.GetBannerByClientType((int)Display.MPhone);
            wm.course3news = _courseInfoAppService.GetCourseInfo3News((int)Display.MPhone);
            List <CourseCategoryListDto> topCategorys = _courseCategoryAppService.GetCourseTopCategoryList();

            foreach (var category in topCategorys)
            {
                category.CourseInfoList = _courseInfoAppService.GetCourseInfoByCategory3News(category.CategoryId, (int)Display.MPhone);
            }
            wm.TopCategory = topCategorys;

            return(View(wm));
        }