public async Task OnGetAsync()
        {
            CoursesList = await _context.Courses.Include(x => x.CourseGrpSetup).Where(x => x.CourseGrpSetup.Id == x.CourseGrpSetupId)
                          .OrderBy(x => x.Name).OrderBy(x => x.CourseGrpSetupId).ToListAsync();

            ViewData["CourseGroup"] = new SelectList(_context.CourseGrpSetup, "Id", "Name");

            NewCourseToApprove = await _context.NewCourseRequests.Where(app => app.Approved == false && app.ReqstType == "course").ToListAsync();

            MessageAlert = $"You have {NewCourseToApprove.Count()} Course(s) Recommended to Setup";
        }
示例#2
0
        public async Task <IActionResult> OnGet()
        {
            ViewData["NationalityId"] = new SelectList(_context.Nationalities, "Id", "Name");
            ViewData["Areaoffice"]    = new SelectList(_context.AreaOffices, "Id", "Description");
            ViewData["BusinessLine"]  = new SelectList(_context.businessLine, "Id", "Description");

            EmployerSuperSetupList = await _context.EmployerSuperSetups.ToListAsync();

            NewCourseToApprove = await _context.NewCourseRequests.Where(app => app.Approved == false && app.ReqstType == "employer").ToListAsync();

            MessageAlert = $"You have {NewCourseToApprove.Count()} Employer(s) Recommended to Setup";
            return(Page());
        }