Esempio n. 1
0
        public ActionResult CommonPrec()
        {
            PatientAllDetails patientDETAILS = (PatientAllDetails)Session["patientDetails"];
            Common            Cm             = new Common();

            //Load lime always null not requird get data
            Cm = BM.GetCommonDetails(patientDETAILS.QueueId, patientDETAILS.CasePapaerNo);
            return(View("PrecCommon", Cm));
        }
        public ActionResult ManagePrecCommonDetails(Common co)
        {
            AdminDetails      admObj         = (AdminDetails)Session["UserDetails"];
            PatientAllDetails patientDETAILS = (PatientAllDetails)Session["patientDetails"];

            ModelState.Clear();
            co.QueueId     = patientDETAILS.QueueId;
            co.HospitalId  = patientDETAILS.HospitalId.ToString();
            co.CreatedBy   = admObj.UserId.ToString();
            co.PatientId   = patientDETAILS.Id.ToString();
            co.CasePaperNo = patientDETAILS.CasePapaerNo;

            //if (imgfile != null)
            //{
            //    string path;
            //    string extension = Path.GetExtension(imgfile.FileName);
            //    string impPath = ConfigurationManager.AppSettings["HistoryDoc"];
            //    path = Path.Combine(Server.MapPath(impPath), Path.GetFileName(imgfile.FileName));
            //    imgfile.SaveAs(path);
            //    co.FileName = imgfile.FileName;
            //    // path = "/UploadImage/" + Path.GetFileName(imgfile.FileName);
            //}

            //else
            //{
            //    co.FileName = "";
            //}


            int Flag = BM.ManagePrecCommonDetails(co);

            if (Flag > 0)
            {
                Common        ob             = new Common();
                List <Common> lstObservation = new List <Common>();
                ob             = BM.GetCommonDetails(patientDETAILS.QueueId, patientDETAILS.CasePapaerNo);
                lstObservation = ob.lst;
                return(Json(lstObservation, JsonRequestBehavior.AllowGet));
            }
            else
            {
                return(Json("", JsonRequestBehavior.AllowGet));
            }
        }