Exemplo n.º 1
0
        public ActionResult DeletePatientMedConfirmed(int id)
        {
            PatientMedicalInformation patientinfo = _db.PatientMedicalInformations.Find(id);

            _db.PatientMedicalInformations.Remove(patientinfo);
            _db.SaveChanges();
            return(RedirectToAction("ViewPatientMedicalInformation"));
        }
Exemplo n.º 2
0
        public ActionResult DetailsForPatientMedicalInformation(int id)
        {
            PatientMedicalInformation patientMedicalDetail = _db.PatientMedicalInformations.Find(id);

            if (patientMedicalDetail == null)
            {
                return(HttpNotFound());
            }
            return(View(patientMedicalDetail));
        }
Exemplo n.º 3
0
        public ActionResult CreateNewMedPatient([Bind(Exclude = "Id")] PatientMedicalInformation patientMedToCreate)
        {
            if (!ModelState.IsValid)
            {
                return(View());
            }


            _db.PatientMedicalInformations.Add(patientMedToCreate);
            _db.SaveChanges();
            return(RedirectToAction("ViewPatientMedicalInformation"));
        }
Exemplo n.º 4
0
        public ActionResult DeletePatientMedicalInformation(int?id)
        {
            if (id == null)
            {
                return(new HttpStatusCodeResult(HttpStatusCode.BadRequest));
            }
            PatientMedicalInformation patientmedinfo = _db.PatientMedicalInformations.Find(id);

            if (patientmedinfo == null)
            {
                return(HttpNotFound());
            }

            return(View(patientmedinfo));
        }