/**
         * <summary>
         * Display the form to collect guardian and alternate contact person information.
         * </summary>
         * */
        public ActionResult GuardianInformation()
        {
            // Is the lottery closed?
            if (IsLotteryClosed()) // TODO implement this as an class-level annotation instead
            {
                return(RedirectToAction(actionName: "LotteryClosed"));
            }

            // Validate the session
            if (!IsActiveSession()) //TODO Do this with AOP/Annotations instead
            {
                return(RedirectToAction("Index"));
            }

            // Get data for view variables
            viewHelper.PrepareGuardianInformationView(ViewBag);
            var applicant = GetSessionApplicant();


            return(View(applicant));
        }
Пример #2
0
 /**
  * <summary>
  * Prepares the view for editing an applicant by populating variables
  * in the ViewBag.
  * </summary>
  *
  * <param name="applicant">The applicant who's data should be populated into the view</param>
  **/
 private void PrepareEditApplicantView(Applicant applicant)
 {
     viewHelper.PrepareStudentInformationView(ViewBag, false);
     viewHelper.PrepareGuardianInformationView(ViewBag);
     viewHelper.PrepareSchoolSelectionView(ViewBag, applicant);
 }