Esempio n. 1
0
        public ActionResult RemoveApplication(int id)
        {
            var repo = new ApplicantDatabase();
            repo.Delete(id);

            return RedirectToAction("ViewApplicant");
        }
Esempio n. 2
0
        public ActionResult EditForm(int id)
        {
            Application application = new Application();
            ApplicantDatabase ad = new ApplicantDatabase();

            application = ad.GetById(id);

            return View(application);
        }
Esempio n. 3
0
        public ActionResult Index(Application application)
        {
            if (ModelState.IsValid)
            {

                var repo = new ApplicantDatabase();
                repo.Add(application);

                return RedirectToAction("ThankYou");
            }

            return View(application);
        }
Esempio n. 4
0
        public ActionResult EditForm(Application application)
        {
            if (ModelState.IsValid)
            {

                var repo = new ApplicantDatabase();
                repo.Edit(application);

                return RedirectToAction("ViewApplicant");
            }

            return View(application);
        }
Esempio n. 5
0
        public ActionResult Form(Application application)
        {
            if (ModelState.IsValid)
            {

                var repo = new ApplicantDatabase();
                repo.Add(application);

               // string name = application.Name;

                return RedirectToAction("ThankYou", application);
            }

            return View(application);
        }
Esempio n. 6
0
        public ActionResult ViewDetails(int id)
        {
            var repo = new ApplicantDatabase();
            var applicant = repo.GetById(id);

            return View(applicant);
        }
Esempio n. 7
0
        public ActionResult ViewApplicant()
        {
            var repo = new ApplicantDatabase();
            var applicants = repo.GetAll();

            return View(applicants);
        }
Esempio n. 8
0
        public JsonResult ViewDetailsJH(string id)
        {
            var repo = new ApplicantDatabase();
            var applicant = repo.GetById(int.Parse(id));

            return Json(applicant, JsonRequestBehavior.AllowGet);
        }