public ActionResult PatientHealthRecord(Screening model, string command) { ArogyaParivarEntities context = new ArogyaParivarEntities(); try { try { T_Vitals Vitals = new T_Vitals() { Height = model.Height, Weight = model.Weight, BMI = model.BMI, SysBP = model.SysBP, DiaBP = model.DiaBP, Temparature = model.Temparature, Pulse = model.Pulse, Respiratory = model.Respiratory, Token_Number = 1 }; T_Screenings screenings = new T_Screenings() { ComplaintID = model.ComplaintID, CheckListID = model.CheckListID, PresentingComplaint = model.PresentingComplaint, PastMedicalHistory = model.PastMedicalHistory, PastSurgicalHistory = model.PastSurgicalHistory, FamilyHistory = model.FamilyHistory, CurrentMedication = model.CurrentMedication, ECGOutcomeID = model.ECGOutcomeID, ScreenOutcomeID = model.ScreenOutcomeID, SpecialtyID = model.SpecialtyID, AppointDate = model.AppointDate, CreateDate = model.CreateDate, Token_Number = 1 }; context.T_Screenings.Add(screenings); context.SaveChanges(); return RedirectToAction("PatientSearch"); } catch { return View(model); } } catch { return View(model); } }
public JsonResult saveVitaltData(Screening model) { try { ArogyaParivarEntities context = new ArogyaParivarEntities(); T_Vitals modelVitals = new T_Vitals() { Height = model.Height, Weight = model.Weight, BMI = model.BMI, SysBP = model.SysBP, Pulse = model.Pulse, DiaBP = model.DiaBP, Temparature = model.Temparature, Respiratory = model.Respiratory, ArogyaID = Session["strArogyaID"].ToString(), UserID = Convert.ToInt32(Session["UserID"]), Token_Number = Convert.ToInt32(Session["intTokenNumber"].ToString()), CreateDate = DateTime.Now, }; context.T_Vitals.Add(modelVitals); context.SaveChanges(); return Json(1, JsonRequestBehavior.AllowGet); } catch { return Json(-1, JsonRequestBehavior.AllowGet); } }