예제 #1
0
        [Authorize] //This will make it so the user must be authorized/logged in with google to access this page
        public ActionResult FandQ(int id)
        {
            programQuestions FAQ = new programQuestions();

            FAQ.Program   = db.Programs.Find(id);
            FAQ.Intern    = db.Interns.ToList();
            FAQ.Questions = db.Question.ToList();
            FAQ.Volunteer = db.Volunteers.ToList();

            ViewBag.ID = id;

            return(View(FAQ));
        }
예제 #2
0
        //This will go to the program view and view that programs info and allow you to access the FAQ page.
        public ActionResult ProgramView(int id)
        {
            programQuestions ProgramQuestions = new programQuestions();

            ProgramQuestions.Program = db.Programs.Find(id);

            ViewBag.Name        = ProgramQuestions.Program.programName;
            ViewBag.WeekdayTime = ProgramQuestions.Program.programDay;
            ViewBag.AgeGroup    = ProgramQuestions.Program.participantAge;
            ViewBag.Description = ProgramQuestions.Program.programDescription;
            //ViewBag.InternName = ProgramQuestions.Intern.internFirstName + ' ' + ProgramQuestions.Intern.internLastName;

            return(View(ProgramQuestions));
        }