Example #1
0
 public void CreateAnesthesiaConcerns(Patient pat)
 {
     foreach (AnesthesiaConcern a in pat.ClinicalFindings.AnesthesiaConcerns)
     {
         a.PatientId = pat.PatientId;
         service.CreateAnesthesiaConcern(a);
     }
 }
Example #2
0
        public void CreateAnestheticPlan(Patient pat)
        {
            if (pat.AnestheticPlan.InhalantPlan.HasValues())
                CreateAnestheticInhalantPlans(pat);

            if (pat.AnestheticPlan.InjectionPlan.HasValues())
                CreateAnestheticInjectionPlans(pat);

            if (pat.AnestheticPlan.PreMedications.HasValues())
                CreateAnestheticPremedications(pat);
        }
Example #3
0
 public void CreateMaintenanceOther(Patient pat)
 {
     pat.Maintenance.MaintenanceOther.PatientId = pat.PatientId;
     service.CreateMaintenanceOther(pat.Maintenance.MaintenanceOther);
 }
Example #4
0
 public ActionResult GetPatient(Patient form)
 {
     Dictionary<string, object> dict = new Dictionary<string, object>();
     try
     {
         dict["Patient"] = service.GetPatient(form.PatientId);
         dict["success"] = true;
     }
     catch (Exception e)
     {
         dict["success"] = false;
         dict["message"] = e.Message;
         dict["source"] = e.StackTrace;
     }
     return Json(dict);
 }
Example #5
0
 public void CreateBloodwork(Patient pat)
 {
     Bloodwork blood = pat.Bloodwork;
     blood.PatientId = pat.PatientId;
     if (blood.Albumin != -1)
         service.CreateBloodwork(blood, "Albumin", blood.Albumin);
     if (blood.ALP != -1)
         service.CreateBloodwork(blood, "ALP", blood.ALP);
     if (blood.ALT != -1)
         service.CreateBloodwork(blood, "ALT", blood.ALT);
     if (blood.BUN != -1)
         service.CreateBloodwork(blood, "BUN", blood.BUN);
     if (blood.Ca != -1)
         service.CreateBloodwork(blood, "Ca", blood.Ca);
     if (blood.Cl != -1)
         service.CreateBloodwork(blood, "Cl", blood.Cl);
     if (blood.CREAT != -1)
         service.CreateBloodwork(blood, "CREAT", blood.CREAT);
     if (blood.Globulin != -1)
         service.CreateBloodwork(blood, "Globulin", blood.Globulin);
     if (blood.Glucose != -1)
         service.CreateBloodwork(blood, "Glucose", blood.Glucose);
     if (blood.iCa != -1)
         service.CreateBloodwork(blood, "iCa", blood.iCa);
     if (blood.K != -1)
         service.CreateBloodwork(blood, "K", blood.K);
     if (blood.NA != -1)
         service.CreateBloodwork(blood, "NA", blood.NA);
     if (blood.PCV != -1)
         service.CreateBloodwork(blood, "PCV", blood.PCV);
     if (blood.TP != -1)
         service.CreateBloodwork(blood, "TP", blood.TP);
     if (blood.USG != -1)
         service.CreateBloodwork(blood, "USG", blood.USG);
     if (blood.WBC != -1)
         service.CreateBloodwork(blood, "WBC", blood.WBC);
     if (blood.OtherType != null && blood.OtherValue != -1)
         service.CreateBloodwork(blood, blood.OtherType, blood.OtherValue);
 }
Example #6
0
 public void CreateAnestheticInhalantPlans(Patient pat)
 {
     pat.AnestheticPlan.InhalantPlan.PatientId = pat.PatientId;
     service.CreateAnestheticPlanInhalant(pat.AnestheticPlan.InhalantPlan);
 }
Example #7
0
        public void Export(Patient p)
        {
            //CALL SAVE FORM
            //CALL GET FORM

            Patient gottenP=  GetPatient(p.PatientId);
            string username = gottenP.PatientInfo.Clinician.Username;

            #region PDF OUTPUT

            Document doc = new Document(PageSize.LETTER);
            doc.SetMargins(0f, 0f, 0f, 0f);

            MemoryStream memStream = new MemoryStream();

            #region MONITORING LOOP

            string MonitoringFullList = "";
            foreach (Monitoring m in gottenP.Monitoring)
            {
                MonitoringFullList += m.Equipment.Label;
            }

            #endregion

            #region ANESTHESIA CONCERNS LOOP

            //string AnesthesiaConcerns = "";
            //foreach (AnesthesiaConcern a in p.ClinicalFindings)
            //{
            //    AnesthesiaConcerns += a.Concern.Label;
            //}

            #endregion

            try
            {
                var imgpath = System.Web.HttpContext.Current.Server.MapPath("~/Images/Test.jpg");
                var pdfpath = System.Web.HttpContext.Current.Server.MapPath(@"~/PDFs/"+username+"_SOAP.pdf");

                Font FivePointFont = new Font(Font.NORMAL, 5f);
                Font SevenPointFont = new Font(Font.NORMAL, 7f);
                Font NinePointFont = new Font(Font.NORMAL, 9f);
                Font ElevenPointFont = new Font(Font.NORMAL, 11f);

                //PdfWriter writer = PdfWriter.GetInstance(doc, new FileStream("../PDFs/SOAP.pdf", FileMode.Create));
                PdfWriter writer = PdfWriter.GetInstance(doc, new FileStream(pdfpath, FileMode.Create));

                doc.Open();

                iTextSharp.text.Image img = iTextSharp.text.Image.GetInstance(imgpath);
                doc.Add(img);

                PdfContentByte cb = writer.DirectContent;
                ColumnText ct = new ColumnText(cb);

                Phrase Anesthetist = new Phrase(gottenP.PatientInfo.Student.Username);

                #region top variables

                Phrase Date = new Phrase(gottenP.PatientInfo.ProcedureDate.ToString());
                Phrase Clinician = new Phrase(gottenP.PatientInfo.Clinician.Username);
                Phrase Stall = new Phrase("");
                Phrase Procedure = new Phrase(gottenP.PatientInfo.Procedure.Label);
                Phrase BodyWeight = new Phrase(gottenP.PatientInfo.BodyWeight.ToString());
                Phrase Age = new Phrase(gottenP.PatientInfo.AgeInYears.ToString() + " years "+gottenP.PatientInfo.AgeInMonths.ToString() + " months");
                Phrase Temperament = new Phrase(gottenP.PatientInfo.Temperament.Label, NinePointFont);

                Phrase Temp = new Phrase(gottenP.ClinicalFindings.Temperature.ToString());
                Phrase Pulse = new Phrase(gottenP.ClinicalFindings.PulseRate.ToString());
                Phrase Response = new Phrase(" ");

                Phrase CardiacAuscultation = new Phrase(gottenP.ClinicalFindings.CardiacAuscultation.Label, NinePointFont);
                Phrase PulseQuality = new Phrase(gottenP.ClinicalFindings.PulseQuality.Label, NinePointFont);
                Phrase MucousMembraneColor = new Phrase(gottenP.ClinicalFindings.MucousMembraneColor.Label, NinePointFont);
                Phrase CapillaryRefillTime = new Phrase(gottenP.ClinicalFindings.CapillaryRefillTime.Label, NinePointFont);
                Phrase RespiratoryAuscultation = new Phrase(gottenP.ClinicalFindings.RespiratoryAuscultation.Label, NinePointFont);
                Phrase PhysicalStatusClassification = new Phrase(gottenP.ClinicalFindings.PhysicalStatusClassification.Label, NinePointFont);

                Phrase ReasonForClassification = new Phrase(gottenP.ClinicalFindings.ReasonForClassification);
                Phrase CurrentMedications = new Phrase(gottenP.ClinicalFindings.CurrentMedications);
                Phrase AnesthesiaConcerns = new Phrase("");

                #endregion

                Phrase Drug1 = new Phrase(gottenP.AnestheticPlan.PreMedications.SedativeDrug.Label, NinePointFont);
                Phrase Route1 = new Phrase(gottenP.AnestheticPlan.PreMedications.Route.Label);
                Phrase Dosage1 = new Phrase(gottenP.AnestheticPlan.PreMedications.SedativeDosage.ToString());
                Phrase DoseMg1 = new Phrase(" ");
                Phrase DoseMl1 = new Phrase(" ");

                Phrase Drug2 = new Phrase(gottenP.AnestheticPlan.PreMedications.OpioidDrug.Label, NinePointFont);
                Phrase Route2 = new Phrase(gottenP.AnestheticPlan.PreMedications.Route.Label);
                Phrase Dosage2 = new Phrase(gottenP.AnestheticPlan.PreMedications.OpioidDosage.ToString());
                Phrase DoseMg2 = new Phrase(" ");
                Phrase DoseMl2 = new Phrase(" ");

                Phrase Drug3 = new Phrase(gottenP.AnestheticPlan.PreMedications.AnticholinergicDrug.Label, NinePointFont);
                Phrase Route3 = new Phrase(gottenP.AnestheticPlan.PreMedications.Route.Label);
                Phrase Dosage3 = new Phrase(gottenP.AnestheticPlan.PreMedications.AnticholinergicDosage.ToString());
                Phrase DoseMg3 = new Phrase(" ");
                Phrase DoseMl3 = new Phrase(" ");

            #region INDUCTIONS

                Phrase InductionDrug1 = new Phrase(gottenP.AnestheticPlan.InhalantPlan.Drug.Label, NinePointFont);
                Phrase InjectableRoute1 = new Phrase(gottenP.AnestheticPlan.InjectionPlan.Route.Label);
                Phrase InjectableDosage1 = new Phrase(gottenP.AnestheticPlan.InhalantPlan.Drug.Label, NinePointFont);
                Phrase InjectableDoseMg1 = new Phrase(" ");
                Phrase InjectableDoseMl1 = new Phrase(" ");

                Phrase InductionDrug2 = new Phrase("");//gottenP.AnestheticPlan.InjectionPlan.Drug.Label, NinePointFont);
                Phrase InductionRoute2 = new Phrase(gottenP.AnestheticPlan.PreMedications.Route.Label);
                Phrase InductionDosage2 = new Phrase(gottenP.AnestheticPlan.PreMedications.AnticholinergicDosage.ToString());
                Phrase InductionDoseMg2 = new Phrase(" ");
                Phrase InductionDoseM2 = new Phrase(" ");
            #endregion

            #region MAINTENANCE
                Phrase Injectable1 = new Phrase(gottenP.Maintenance.MaintenanceInjectionDrug.Drug.Label, NinePointFont);

                Phrase MaintenaceInjectable = new Phrase(gottenP.Maintenance.MaintenanceInjectionDrug.Drug.Label, NinePointFont);
                Phrase MaintenanceInhalant = new Phrase(gottenP.Maintenance.MaintenanceInhalantDrug.Drug.Label, NinePointFont);

                Phrase MaintenanceInhalantInductionPercent = new Phrase("");//gottenP.Maintenance.MaintenanceInhalantDrug.InductionPercentage.ToString);
                //Phrase MaintenanceInhalantInductionPercent = new Phrase("");

                Phrase OxygenFlowRate = new Phrase("");

                Phrase BreathingSystem = new Phrase("x");

                Phrase IntraoperativeAnalgesia = new Phrase(gottenP.Maintenance.MaintenanceOther.IntraoperativeAnalgesia.Label);
                Phrase OtherAnestheticDrugs = new Phrase(gottenP.Maintenance.MaintenanceOther.OtherAnestheticDrug, NinePointFont);
                Phrase Monitoring = new Phrase(MonitoringFullList, NinePointFont);

                Phrase IVFluidType = new Phrase(gottenP.Maintenance.MaintenanceOther.IVFluidType.Label, FivePointFont);
                Phrase IVDoseMl1 = new Phrase("XX.XX");
                Phrase IVDoseDrops1 = new Phrase("XXX");

                Phrase MiniDrip = new Phrase("");
                Phrase MaxiDrip = new Phrase("");

                Phrase PreOpPainAssessment = new Phrase(gottenP.PatientInfo.PreOperationPainAssessment.Label);
                Phrase PostOpPainAssessment = new Phrase(gottenP.PatientInfo.PostOperationPainAssessment.Label);
            #endregion

                #region Small Drugs

                Phrase PVC = new Phrase(gottenP.Bloodwork.PCV.ToString(), NinePointFont);
                if (gottenP.Bloodwork.PCV == -1) {PVC = new Phrase("0", NinePointFont); };

                Phrase TP = new Phrase(gottenP.Bloodwork.TP.ToString(), NinePointFont);
                if (gottenP.Bloodwork.TP == -1) { TP = new Phrase("0", NinePointFont); };

                Phrase Alb = new Phrase(gottenP.Bloodwork.Albumin.ToString(), NinePointFont);
                if (gottenP.Bloodwork.Albumin == -1) { Alb = new Phrase("0", NinePointFont); };

                Phrase Glob = new Phrase(gottenP.Bloodwork.Globulin.ToString(), NinePointFont);
                if (gottenP.Bloodwork.Globulin == -1) { Glob = new Phrase("0", NinePointFont); };

                Phrase WBC = new Phrase(gottenP.Bloodwork.WBC.ToString(), NinePointFont);
                if (gottenP.Bloodwork.WBC == -1) { WBC = new Phrase("0", NinePointFont); };

                Phrase Na = new Phrase(gottenP.Bloodwork.NA.ToString(), NinePointFont);
                if (gottenP.Bloodwork.NA == -1) { Na = new Phrase("0", NinePointFont); };

                Phrase K = new Phrase(gottenP.Bloodwork.K.ToString(), NinePointFont);
                if (gottenP.Bloodwork.K == -1) { K = new Phrase("0", NinePointFont); };

                Phrase Cl = new Phrase(gottenP.Bloodwork.Cl.ToString(), NinePointFont);
                if (gottenP.Bloodwork.Cl == -1) { Cl = new Phrase("0", NinePointFont); };

                Phrase Ca = new Phrase(gottenP.Bloodwork.Ca.ToString(), NinePointFont);
                if (gottenP.Bloodwork.Ca == -1) { Ca = new Phrase("0", NinePointFont); };

                Phrase iCa = new Phrase(gottenP.Bloodwork.iCa.ToString(), NinePointFont);
                if (gottenP.Bloodwork.iCa == -1) { iCa = new Phrase("0", NinePointFont); };

                Phrase Glucose = new Phrase(gottenP.Bloodwork.Glucose.ToString(), NinePointFont);
                if (gottenP.Bloodwork.Glucose == -1) { Glucose = new Phrase("0", NinePointFont); };

                Phrase ALT = new Phrase(gottenP.Bloodwork.ALT.ToString(), NinePointFont);
                if (gottenP.Bloodwork.ALT == -1) { ALT = new Phrase("0", NinePointFont); };

                Phrase ALP = new Phrase(gottenP.Bloodwork.ALP.ToString(), NinePointFont);
                if (gottenP.Bloodwork.ALP == -1) { ALP = new Phrase("0", NinePointFont); };

                Phrase BUN = new Phrase(gottenP.Bloodwork.BUN.ToString(), NinePointFont);
                if (gottenP.Bloodwork.BUN == -1) { BUN = new Phrase("0", NinePointFont); };

                Phrase CREAT = new Phrase(gottenP.Bloodwork.CREAT.ToString(), NinePointFont);
                if (gottenP.Bloodwork.CREAT == -1) { CREAT = new Phrase("0", NinePointFont); };

                Phrase USG = new Phrase(gottenP.Bloodwork.USG.ToString(), NinePointFont);
                if (gottenP.Bloodwork.USG == -1) { USG = new Phrase("0", NinePointFont); };

                Phrase OtherProblems = new Phrase(gottenP.Bloodwork.OtherType);

                Phrase OtherAnesthesia = new Phrase(gottenP.Bloodwork.OtherValue.ToString());

                #endregion

                //parameters of SetSimpleColumn: (Phrase, leftmargin coordinate, bottommargin coordinate, box width, box height, line height, alignment)
                //NOTE: all dimensions start at the BOTTOM LEFT of the PDF... why? I dont f*****g know, its retarded.
                //NOTE: bottommargin determines x coordinate

                //                          LEFT     BOT     WIDTH    HEIGHT   LINE HEIGHT          ALIGN

                #region TOP HALF

                ct.SetSimpleColumn(Anesthetist, 122, 752, 280, 767, 15, Element.ALIGN_LEFT);
                ct.Go();   //ANESTHETIST

                ct.SetSimpleColumn(Date, 77, 736, 290, 751, 15, Element.ALIGN_LEFT);
                ct.Go();   //DATE

                ct.SetSimpleColumn(Clinician, 108, 723, 280, 738, 15, Element.ALIGN_LEFT);
                ct.Go();   //Clinician

                ct.SetSimpleColumn(Stall, 185, 709, 280, 724, 15, Element.ALIGN_LEFT);
                ct.Go();   //Stall

                ct.SetSimpleColumn(Procedure, 116, 683, 280, 698, 15, Element.ALIGN_LEFT);
                ct.Go();   //Procedure

                ct.SetSimpleColumn(BodyWeight, 127, 655, 161, 670, 15, Element.ALIGN_LEFT);
                ct.Go();  //Body Weight

                ct.SetSimpleColumn(Age, 235, 655, 525, 670, 15, Element.ALIGN_LEFT);
                ct.Go();  //Age

                ct.SetSimpleColumn(Temperament, 138, 628, 525, 643, 15, Element.ALIGN_LEFT);
                ct.Go();  //Temperment

                ct.SetSimpleColumn(Temp, 63, 598, 107, 613, 15, Element.ALIGN_LEFT);
                ct.Go();  //Temp

                ct.SetSimpleColumn(Pulse, 135, 598, 165, 613, 15, Element.ALIGN_LEFT);
                ct.Go();  //Pulse

                ct.SetSimpleColumn(Response, 207, 598, 250, 613, 15, Element.ALIGN_LEFT);
                ct.Go();  //Response

                ct.SetSimpleColumn(CardiacAuscultation, 136, 584, 250, 599, 15, Element.ALIGN_LEFT);
                ct.Go();  //Cardiac Auscultation

                ct.SetSimpleColumn(PulseQuality, 101, 571, 250, 586, 15, Element.ALIGN_LEFT);
                ct.Go();  //PulseQuality

                ct.SetSimpleColumn(MucousMembraneColor, 155, 557, 250, 572, 15, Element.ALIGN_LEFT);
                ct.Go();  //Mucous Membrane Color

                ct.SetSimpleColumn(CapillaryRefillTime, 139, 543, 250, 558, 15, Element.ALIGN_LEFT);
                ct.Go();  //Capillary Refill Time

                ct.SetSimpleColumn(RespiratoryAuscultation, 154, 529, 250, 544, 15, Element.ALIGN_LEFT);
                ct.Go();  //Respiratory Auscultation

                ct.SetSimpleColumn(PhysicalStatusClassification, 176, 516, 250, 531, 15, Element.ALIGN_LEFT);
                ct.Go();  //Physical Status Classification

                ct.SetSimpleColumn(ReasonForClassification, 40, 447, 250, 502, 15, Element.ALIGN_LEFT);
                ct.Go();  //Physical Status Classification

                ct.SetSimpleColumn(CurrentMedications, 30, 446, 250, 476, 15, Element.ALIGN_LEFT);
                ct.Go();  //CurrentMedication

                #endregion

                #region DRUGS
                //       LEFT     BOT     WIDTH    HEIGHT   LINE HEIGHT          ALIGN

                ct.SetSimpleColumn(AnesthesiaConcerns, 40, 400, 550, 425, 15, Element.ALIGN_LEFT);
                ct.Go();  //Physical Status Classification

                ct.SetSimpleColumn(Drug1, 95, 363, 200, 378, 15, Element.ALIGN_LEFT);
                ct.Go();  //Drug

                ct.SetSimpleColumn(Route1, 201, 363, 270, 378, 15, Element.ALIGN_LEFT);
                ct.Go();  //Route

                ct.SetSimpleColumn(Dosage1, 271, 363, 385, 378, 15, Element.ALIGN_LEFT);
                ct.Go();  //Dosage

                ct.SetSimpleColumn(DoseMg1, 385, 363, 455, 378, 15, Element.ALIGN_LEFT);
                ct.Go();  //DoseMG

                ct.SetSimpleColumn(DoseMl1, 456, 363, 550, 378, 15, Element.ALIGN_LEFT);
                ct.Go();  //DoseML

                ct.SetSimpleColumn(Drug2, 95, 348, 200, 363, 15, Element.ALIGN_LEFT);
                ct.Go();  //Drug

                ct.SetSimpleColumn(Route2, 201, 348, 270, 363, 15, Element.ALIGN_LEFT);
                ct.Go();  //Route

                ct.SetSimpleColumn(Dosage2, 271, 348, 385, 363, 15, Element.ALIGN_LEFT);
                ct.Go();  //Dosage

                ct.SetSimpleColumn(DoseMg2, 385, 348, 455, 363, 15, Element.ALIGN_LEFT);
                ct.Go();  //DoseMG

                ct.SetSimpleColumn(DoseMl2, 456, 348, 550, 363, 15, Element.ALIGN_LEFT);
                ct.Go();  //DoseML

                ct.SetSimpleColumn(Drug3, 95, 333, 200, 348, 15, Element.ALIGN_LEFT);
                ct.Go();  //Drug3

                ct.SetSimpleColumn(Route3, 201, 333, 270, 348, 15, Element.ALIGN_LEFT);
                ct.Go();  //Route3

                ct.SetSimpleColumn(Dosage3, 271, 333, 385, 348, 15, Element.ALIGN_LEFT);
                ct.Go();  //Dosage3

                ct.SetSimpleColumn(DoseMg3, 385, 333, 455, 348, 15, Element.ALIGN_LEFT);
                ct.Go();  //DoseMG3

                ct.SetSimpleColumn(DoseMl3, 456, 333, 550, 348, 15, Element.ALIGN_LEFT);
                ct.Go();  //DoseML3

                #endregion

                #region INDUCTION

                ct.SetSimpleColumn(InductionDrug1, 95, 320, 200, 335, 15, Element.ALIGN_LEFT);
                ct.Go();  //Drug

                ct.SetSimpleColumn(Route1, 201, 320, 270, 335, 15, Element.ALIGN_LEFT);
                ct.Go();  //Route

                ct.SetSimpleColumn(Dosage1, 271, 320, 385, 335, 15, Element.ALIGN_LEFT);
                ct.Go();  //Dosage

                ct.SetSimpleColumn(DoseMg1, 385, 320, 455, 335, 15, Element.ALIGN_LEFT);
                ct.Go();  //DoseMG

                ct.SetSimpleColumn(DoseMl1, 456, 320, 550, 335, 15, Element.ALIGN_LEFT);
                ct.Go();  //DoseML

                ct.SetSimpleColumn(InductionDrug2, 95, 305, 200, 320, 15, Element.ALIGN_LEFT);
                ct.Go();  //Drug2

                ct.SetSimpleColumn(Route1, 201, 305, 270, 320, 15, Element.ALIGN_LEFT);
                ct.Go();  //Route2

                ct.SetSimpleColumn(Dosage1, 271, 305, 385, 320, 15, Element.ALIGN_LEFT);
                ct.Go();  //Dosage2

                ct.SetSimpleColumn(DoseMg1, 385, 305, 455, 320, 15, Element.ALIGN_LEFT);
                ct.Go();  //DoseMG

                ct.SetSimpleColumn(DoseMl1, 456, 305, 550, 320, 15, Element.ALIGN_LEFT);
                ct.Go();  //DoseML2
                #endregion

                #region MIDDLE HALF

                ct.SetSimpleColumn(MaintenaceInjectable, 180, 295, 550, 310, 15, Element.ALIGN_LEFT);
                ct.Go();  //MaintenaceInjectable

                ct.SetSimpleColumn(MaintenanceInhalant, 180, 280, 275, 295, 15, Element.ALIGN_LEFT);
                ct.Go();  //InhalantType

                ct.SetSimpleColumn(MaintenanceInhalantInductionPercent, 334, 280, 390, 295, 15, Element.ALIGN_LEFT);
                ct.Go();  //InhalantInductionPercent

                ct.SetSimpleColumn(MaintenanceInhalantInductionPercent, 495, 280, 536, 295, 15, Element.ALIGN_LEFT);
                ct.Go();  //InhalantMaintenancePercent

                ct.SetSimpleColumn(OxygenFlowRate, 210, 267, 275, 282, 15, Element.ALIGN_LEFT);
                ct.Go();  //OxygenFlowRate

                ct.SetSimpleColumn(MaintenanceInhalantInductionPercent, 334, 267, 390, 282, 15, Element.ALIGN_LEFT);
                ct.Go();  //InhalantInductionPercent

                ct.SetSimpleColumn(MaintenanceInhalantInductionPercent, 495, 267, 536, 282, 15, Element.ALIGN_LEFT);
                ct.Go();  //InhalantMaintenancePercent

                ct.SetSimpleColumn(MaintenanceInhalantInductionPercent, 495, 267, 536, 282, 15, Element.ALIGN_LEFT);
                ct.Go();  //InhalantMaintenancePercent

                #endregion

                #region LOWERHALF

                //TODO: Add if statement for either or checkbox option

                ct.SetSimpleColumn(BreathingSystem, 193, 200, 210, 270, 15, Element.ALIGN_LEFT);
                ct.Go();  //BreathingSystem

                ct.SetSimpleColumn(BreathingSystem, 237, 200, 275, 270, 15, Element.ALIGN_LEFT);
                ct.Go();  //BreathingSystem

                ct.SetSimpleColumn(IntraoperativeAnalgesia, 35, 225, 575, 240, 15, Element.ALIGN_LEFT);
                ct.Go();  //IntraoperativeAnalgesia

                ct.SetSimpleColumn(OtherAnestheticDrugs, 145, 212, 575, 227, 15, Element.ALIGN_LEFT);
                ct.Go();  //OtherAnestheticDrugs

                ct.SetSimpleColumn(Monitoring, 101, 145, 575, 200, 15, Element.ALIGN_LEFT);
                ct.Go();  //Monitoring

                //                          LEFT     BOT     WIDTH    HEIGHT   LINE HEIGHT          ALIGN

                ct.SetSimpleColumn(IVFluidType, 105, 130, 232, 145, 15, Element.ALIGN_LEFT);
                ct.Go();  //IVFluidType

                ct.SetSimpleColumn(IVDoseMl1, 278, 130, 333, 145, 15, Element.ALIGN_LEFT);
                ct.Go();  //IVDoseMl1

                ct.SetSimpleColumn(IVDoseDrops1, 373, 130, 445, 145, 15, Element.ALIGN_LEFT);
                ct.Go();  //IVDoseDrops

                ct.SetSimpleColumn(IVFluidType, 105, 116, 232, 131, 15, Element.ALIGN_LEFT);
                ct.Go();  //IVFluidType

                ct.SetSimpleColumn(IVDoseMl1, 278, 116, 333, 131, 15, Element.ALIGN_LEFT);
                ct.Go();  //IVDoseMl1

                ct.SetSimpleColumn(IVDoseDrops1, 373, 116, 445, 131, 15, Element.ALIGN_LEFT);
                ct.Go();  //IVDoseDrops

                ct.SetSimpleColumn(MaxiDrip, 127, 103, 135, 118, 15, Element.ALIGN_LEFT);
                ct.Go();  //MaxiDrip

                ct.SetSimpleColumn(MiniDrip, 271, 103, 280, 118, 15, Element.ALIGN_LEFT);
                ct.Go();  //MiniDrip

                ct.SetSimpleColumn(PreOpPainAssessment, 275, 583, 575, 613, 15, Element.ALIGN_LEFT);
                ct.Go();    //PreOpPainAssessment

                ct.SetSimpleColumn(PostOpPainAssessment, 275, 550, 575, 573, 15, Element.ALIGN_LEFT);
                ct.Go();    //PostOpPainAssessment

                #endregion

                #region OTHER MISC. DRUGS

                //                          LEFT     BOT     WIDTH    HEIGHT   LINE HEIGHT          ALIGN

                ct.SetSimpleColumn(PVC, 340, 530, 377, 545, 15, Element.ALIGN_LEFT);
                ct.Go();    //PVC

                ct.SetSimpleColumn(TP, 388, 530, 545, 545, 15, Element.ALIGN_LEFT);
                ct.Go();    //TP

                ct.SetSimpleColumn(Alb, 443, 530, 550, 545, 15, Element.ALIGN_LEFT);
                ct.Go();    //Alb

                ct.SetSimpleColumn(Glob, 490, 530, 550, 545, 15, Element.ALIGN_LEFT);
                ct.Go();    //Glob

                ct.SetSimpleColumn(WBC, 542, 530, 575, 545, 15, Element.ALIGN_LEFT);
                ct.Go();    //WBC

                ct.SetSimpleColumn(Na, 340, 515, 500, 530, 15, Element.ALIGN_LEFT);
                ct.Go();    //Na

                ct.SetSimpleColumn(K, 388, 515, 550, 530, 15, Element.ALIGN_LEFT);
                ct.Go();    //K

                ct.SetSimpleColumn(Cl, 443, 515, 550, 530, 15, Element.ALIGN_LEFT);
                ct.Go();    //Cl

                ct.SetSimpleColumn(Ca, 490, 515, 550, 530, 15, Element.ALIGN_LEFT);
                ct.Go();    //Ca

                ct.SetSimpleColumn(iCa, 542, 515, 575, 530, 15, Element.ALIGN_LEFT);
                ct.Go();    //iCa

                ct.SetSimpleColumn(Glucose, 355, 503, 440, 518, 15, Element.ALIGN_LEFT);
                ct.Go();    //Glucose

                ct.SetSimpleColumn(ALT, 448, 503, 545, 518, 15, Element.ALIGN_LEFT);
                ct.Go();    //ALT

                ct.SetSimpleColumn(ALP, 515, 503, 550, 518, 15, Element.ALIGN_LEFT);
                ct.Go();    //ALP

                ct.SetSimpleColumn(BUN, 343, 448, 440, 503, 15, Element.ALIGN_LEFT);
                ct.Go();    //BUN

                ct.SetSimpleColumn(CREAT, 435, 448, 545, 503, 15, Element.ALIGN_LEFT);
                ct.Go();    //CREAT

                ct.SetSimpleColumn(USG, 512, 448, 550, 503, 15, Element.ALIGN_LEFT);
                ct.Go();    //USG

                ct.SetSimpleColumn(OtherProblems, 380, 475, 550, 490, 15, Element.ALIGN_LEFT);
                ct.Go();    //Other Problems

                ct.SetSimpleColumn(OtherAnesthesia, 477, 462, 580, 477, 15, Element.ALIGN_LEFT);
                ct.Go();    //OtherAnesthesia (Prior)

                #endregion

            }

            catch (Exception e)
            {
                throw e;
            }
            finally
            {
                doc.Close();
            }

            #endregion
        }
Example #8
0
 public void DeletePatient(Patient pat)
 {
     DeleteMonitoring(pat);
     DeleteMaintenance(pat);
     DeleteAnestheticPlan(pat);
     DeleteBloodworkGroup(pat);
     DeleteClinicalFindings(pat);
     service.DeletePatient(pat.PatientId);
 }
Example #9
0
 public void DeleteAnestheticPlanInjections(Patient pat)
 {
     service.DeleteAnestheticPlanInjection(pat.PatientId);
 }
Example #10
0
 public void DeleteAnestheticPlanInhalants(Patient pat)
 {
     service.DeleteAnestheticPlanInhalant(pat.PatientId);
 }
Example #11
0
 public void DeleteAnestheticPlan(Patient pat)
 {
     DeleteAnestheticPlanPremedications(pat);
     DeleteAnestheticPlanInjections(pat);
     DeleteAnestheticPlanInhalants(pat);
 }
Example #12
0
 public void DeleteAnesthesiaConcerns(Patient pat)
 {
     service.DeleteAnesthesiaConcern(pat.PatientId);
 }
Example #13
0
 public void CreatePriorAnesthesia(Patient pat)
 {
     pat.ClinicalFindings.PriorAnesthesia.PatientId = pat.PatientId;
     service.CreatePriorAnesthesia(pat.ClinicalFindings.PriorAnesthesia);
 }
Example #14
0
        public void CreatePatient(Patient pat)
        {
            pat.PatientId = service.CreatePatient(pat);
            if (pat.ClinicalFindings.ContainsValue())
                CreateClinicalFindings(pat);

            if (pat.Bloodwork.HasValues())
                CreateBloodwork(pat);

            if (pat.AnestheticPlan != null)
                CreateAnestheticPlan(pat);

            if (pat.Maintenance != null)
                CreateMaintenance(pat);

            if (pat.Monitoring.Count > 0)
                CreateMonitoring(pat);
        }
Example #15
0
 public void CreateMonitoring(Patient pat)
 {
     foreach (Monitoring m in pat.Monitoring)
     {
         m.PatientId = pat.PatientId;
         service.CreateMonitoring(m);
     }
 }
Example #16
0
 public void DeleteMaintenanceOther(Patient pat)
 {
     service.DeleteMaintenanceOther(pat.PatientId);
 }
Example #17
0
 public void DeleteMonitoring(Patient pat)
 {
     service.DeleteMonitoring(pat.PatientId);
 }
Example #18
0
 public void DeleteAnestheticPlanPremedications(Patient pat)
 {
     service.DeleteAnestheticPlanPremedication(pat.PatientId);
 }
Example #19
0
 public void DeletePriorAnesthesia(Patient pat)
 {
     service.DeletePriorAnesthesia(pat.PatientId);
 }
Example #20
0
 public void DeleteBloodworkGroup(Patient pat)
 {
     service.DeleteBloodwork(pat.PatientId);
 }
Example #21
0
 public void DeleteClinicalFindings(Patient pat)
 {
     DeleteCurrentMedications(pat);
     DeletePriorAnesthesia(pat);
     DeleteAnesthesiaConcerns(pat);
     service.DeleteClinicalFinding(pat.PatientId);
 }
Example #22
0
 public void DeleteCurrentMedications(Patient pat)
 {
     service.DeleteCurrentMedication(pat.PatientId);
 }
Example #23
0
 public void CreateAnestheticInjectionPlans(Patient pat)
 {
     pat.AnestheticPlan.InjectionPlan.PatientId = pat.PatientId;
     service.CreateAnestheticPlanInjection(pat.AnestheticPlan.InjectionPlan);
 }
Example #24
0
 public void DeleteMaintenance(Patient pat)
 {
     DeleteMaintenanceInjectionDrugs(pat);
     DeleteMaintenanceInhalantDrugs(pat);
     DeleteMaintenanceOther(pat);
 }
Example #25
0
 public void CreateAnestheticPremedications(Patient pat)
 {
     pat.AnestheticPlan.PreMedications.PatientId = pat.PatientId;
     service.CreateAnestheticPlanPremedication(pat.AnestheticPlan.PreMedications);
 }
Example #26
0
 public void DeleteMaintenanceInhalantDrugs(Patient pat)
 {
     service.DeleteMaintenanceInhalantDrug(pat.PatientId);
 }
Example #27
0
 public ActionResult ExportToPdf(Patient p)
 {
     Dictionary<string, object> dict = new Dictionary<string, object>();
     try
     {
         service.Export(p);
         dict["success"] = true;
     }
     catch
     {
         dict["success"] = false;
     }
     return Json(dict);
 }
Example #28
0
 public void DeleteMaintenanceInjectionDrugs(Patient pat)
 {
     service.DeleteMaintenanceInjectionDrug(pat.PatientId);
 }
Example #29
0
 public ActionResult CreateForm(Patient pat)
 {
     Dictionary<string, object> dict = new Dictionary<string, object>();
     try
     {
         service.CreatePatient(pat);
         dict["patientId"] = pat.PatientId;
         dict["success"] = true;
     }
     catch (Exception e)
     {
         service.DeletePatient(pat);
         dict["success"] = false;
         dict["message"] = e.Message;
         dict["stacktrace"] = e.StackTrace;
     }
     return Json(dict);
 }
Example #30
0
 public void CreateMaintenanceInjectionDrugs(Patient pat)
 {
     pat.Maintenance.MaintenanceInjectionDrug.PatientId = pat.PatientId;
     service.CreateMaintenanceInjectionDrug(pat.Maintenance.MaintenanceInjectionDrug);
 }