public MedicalInformationDetails GetMedicalInfoDetails(string CPno) { try { SqlParameter[] sqlparam; sqlparam = new SqlParameter[2]; sqlparam[0] = new SqlParameter("@flag", "1"); sqlparam[1] = new SqlParameter("@CPno", CPno); DataTable ds = CommonFunction.GetDataTable("USP_Get_Precription", sqlparam, ""); MedicalInformationDetails Ob = new MedicalInformationDetails(); List <MedicalInformationDetails> lst = new List <MedicalInformationDetails>(); if (ds != null && ds.Rows.Count > 0) { DataTable dt = ds; foreach (DataRow dr in dt.Rows) { MedicalInformationDetails Model = new MedicalInformationDetails(); CommonFunction.ReflectSingleData(Ob, dr); lst.Add(Model); } } Ob.lst = lst; return(Ob); } catch (Exception Ex) { throw Ex; } }
public int ManageMedicalInfoDetails(MedicalInformationDetails MI) { try { SqlParameter[] sqlparam; sqlparam = new SqlParameter[17]; sqlparam[0] = new SqlParameter("@Id", MI.Id); sqlparam[1] = new SqlParameter("@Diabetes", MI.Diabetes); sqlparam[2] = new SqlParameter("@Asthma", MI.Asthma); sqlparam[3] = new SqlParameter("@ThyroidProblem", MI.ThyroidProblem); sqlparam[4] = new SqlParameter("@Jaundice", MI.Jaundice); sqlparam[5] = new SqlParameter("@Migraine", MI.Migraine); sqlparam[6] = new SqlParameter("@AIDS", MI.AIDS); sqlparam[7] = new SqlParameter("@HeartProblem", MI.HeartProblem); sqlparam[8] = new SqlParameter("@BloodPressure", MI.BloodPressure); sqlparam[9] = new SqlParameter("@TB", MI.TB); sqlparam[10] = new SqlParameter("@Cancer", MI.Cancer); sqlparam[11] = new SqlParameter("@Other", MI.Other); sqlparam[12] = new SqlParameter("@Allegies", MI.Allegies); sqlparam[13] = new SqlParameter("@CasePaperNo", MI.CasePaperNo); sqlparam[14] = new SqlParameter("@HospitalId", MI.HospitalId); sqlparam[15] = new SqlParameter("@PatientId", MI.PatientId); sqlparam[16] = new SqlParameter("@CreatedBy", MI.CreatedBy); return(CommonFunction.Save("[USP_PD_MedicalInformationDetails]", sqlparam, "")); } catch (Exception) { throw; } }
public ActionResult PatientMedicalDetails() { PatientAllDetails patientDETAILS = (PatientAllDetails)Session["patientDetails"]; MedicalInformationDetails MD = new MedicalInformationDetails(); //Load lime always null not requird get data MD = BM.GetMedicalInfoDetails(patientDETAILS.CasePapaerNo); return(View("MedicalInformation", MD)); }
public ActionResult ManageMedicalInfoDetails(MedicalInformationDetails MI) { AdminDetails admObj = (AdminDetails)Session["UserDetails"]; PatientAllDetails patientDETAILS = (PatientAllDetails)Session["patientDetails"]; ModelState.Clear(); MI.HospitalId = Convert.ToInt16(patientDETAILS.HospitalId); MI.CreatedBy = admObj.UserId; MI.PatientId = patientDETAILS.Id; MI.CasePaperNo = patientDETAILS.CasePapaerNo; //Ob.CasePaperNo = int Flag = BM.ManageMedicalInfoDetails(MI); //MedicalInformationDetails ob = new MedicalInformationDetails(); //List<MedicalInformationDetails> lstVI = new List<MedicalInformationDetails>(); //ob = BM.GetMedicalInfoDetails(patientDETAILS.CasePapaerNo); //lstVI = ob.lst; return(RedirectToAction("PatientMedicalDetails", "MyOPD")); }
public int ManageMedicalInfoDetails(MedicalInformationDetails MI) { return DM.ManageMedicalInfoDetails(MI); }