예제 #1
0
 public static string objToNumStr(object obj)
 {
     if (obj == null)
     {
         return("");
     }
     return(DrawItems.objToNumStr(obj, 2));
 }
예제 #2
0
 public static string strToDate(object dateValue)
 {
     if (dateValue == null)
     {
         return("");
     }
     return(DrawItems.strToDate(dateValue, 1));
 }
예제 #3
0
        public static FixedDocumentSequence setPage(string strFilename, List <ListValue> dicVal)
        {
            int num = 0;

            if (string.IsNullOrEmpty(strFilename))
            {
                return(null);
            }
            XpsDocument           xpsDocument           = new XpsDocument(strFilename, FileAccess.Read);
            FixedDocumentSequence fixedDocumentSequence = xpsDocument.GetFixedDocumentSequence();

            foreach (DocumentReference current in fixedDocumentSequence.References)
            {
                bool          forceReload = false;
                FixedDocument document    = current.GetDocument(forceReload);
                foreach (PageContent current2 in document.Pages)
                {
                    FixedPage pageRoot = current2.GetPageRoot(forceReload);
                    Canvas    canvas   = new Canvas();
                    canvas.Width      = pageRoot.Width;
                    canvas.Height     = pageRoot.Height;
                    canvas.Background = Brushes.Transparent;
                    canvas.Language   = XmlLanguage.GetLanguage("en-us");
                    int arg_A8_0          = pageRoot.Children.Count;
                    List <UIElement> list = new List <UIElement>();
                    for (int i = 0; i < pageRoot.Children.Count; i++)
                    {
                        num++;
                        UIElement uIElement = pageRoot.Children[i];
                        if (uIElement is Glyphs)
                        {
                            Glyphs glyphs        = (Glyphs)uIElement;
                            string unicodeString = glyphs.UnicodeString;
                            if (Regex.IsMatch(unicodeString, "\\{.*?\\}"))
                            {
                                list.Add(pageRoot.Children[i]);
                                UIElement uIElement2 = DrawItems.ReplaceMark(glyphs, dicVal);
                                if (uIElement2 != null)
                                {
                                    canvas.Children.Add(uIElement2);
                                }
                            }
                        }
                    }
                    foreach (UIElement current3 in list)
                    {
                        pageRoot.Children.Remove(current3);
                    }
                    pageRoot.Children.Add(canvas);
                    ((IAddChild)current2).AddChild(pageRoot);
                }
            }
            xpsDocument.Close();
            return(fixedDocumentSequence);
        }
예제 #4
0
        public FixedDocumentSequence getReport()
        {
            List <ListValue> list = null;

            if (!string.IsNullOrEmpty(this.CardID))
            {
                RecordsBaseInfoModel model = new RecordsBaseInfoBLL().GetModel(this.CardID);

                list = new List <ListValue>
                {
                    new ListValue
                    {
                        strMark = "$archiveid",
                        strVal  = model.RecordID
                    },
                    new ListValue
                    {
                        strMark = "$name",
                        strVal  = model.CustomerName
                    }
                };

                ChronicLungerFirstVisitModel model2 = new ChronicLungerFirstVisitBLL().GetModel(this.CardID);
                if (model2 != null)
                {
                    ChronicLungerVisitModel model1 = new ChronicLungerVisitBLL().GetModelByOutKey(model2.ID, "1");

                    if (model1 != null)
                    {
                        list.Add(new ListValue
                        {
                            strMark = "$sfrq1",
                            strVal  = DrawItems.strToDate(model1.FollowupDate)
                        });

                        list.Add(new ListValue
                        {
                            strMark = "$m1",
                            strVal  = DrawItems.objToNumStr(model1.CureMonth, 0)
                        });

                        list.Add(new ListValue
                        {
                            strMark = "#ddryxz1",
                            strVal  = model1.Supervisor
                        });

                        list.Add(new ListValue
                        {
                            strMark = "#sffs1",
                            strVal  = model1.FollowupWay
                        });

                        string strSymptom1 = "";
                        if (!string.IsNullOrEmpty(model1.Symptom))
                        {
                            foreach (string str in model1.Symptom.Split(new char[] { ',' }))
                            {
                                if (!string.IsNullOrEmpty(str))
                                {
                                    strSymptom1 += (int.Parse(str) - 1).ToString() + ",";
                                }
                            }
                            strSymptom1 = strSymptom1.Remove(strSymptom1.Length - 1);
                        }
                        list.Add(new ListValue
                        {
                            strMark = "#zz1",
                            strVal  = strSymptom1
                        });

                        list.Add(new ListValue
                        {
                            strMark = "%zzqt1",
                            strVal  = model1.SymptomEx
                        });

                        list.Add(new ListValue
                        {
                            strMark = "$y1",
                            strVal  = DrawItems.objToNumStr(model1.SmokeDayNum, 0)
                        });

                        list.Add(new ListValue
                        {
                            strMark = "$ny1",
                            strVal  = DrawItems.objToNumStr(model1.NextSmokeDayNum, 0)
                        });

                        list.Add(new ListValue
                        {
                            strMark = "$j1",
                            strVal  = DrawItems.objToNumStr(model1.DayDrinkVolume, 0)
                        });

                        list.Add(new ListValue
                        {
                            strMark = "$nj1",
                            strVal  = DrawItems.objToNumStr(model1.NextDayDrinkVolume, 0)
                        });

                        list.Add(new ListValue
                        {
                            strMark = "%hlfa1",
                            strVal  = model1.ChemotherapyScheme
                        });

                        list.Add(new ListValue
                        {
                            strMark = "#yf1",
                            strVal  = model1.MedicationCompliance
                        });

                        list.Add(new ListValue
                        {
                            strMark = "#ypjx1",
                            strVal  = model1.DrugType
                        });

                        list.Add(new ListValue
                        {
                            strMark = "$lfycs1",
                            strVal  = DrawItems.objToNumStr(model1.OmissiveTimes, 0)
                        });

                        list.Add(new ListValue
                        {
                            strMark = "#ywfy1",
                            strVal  = model1.Adr
                        });

                        list.Add(new ListValue
                        {
                            strMark = "$fy1",
                            strVal  = model1.AdrEx
                        });

                        list.Add(new ListValue
                        {
                            strMark = "#bfz1",
                            strVal  = model1.Complication
                        });

                        list.Add(new ListValue
                        {
                            strMark = "$hbz1",
                            strVal  = model1.ComplicationEx
                        });

                        list.Add(new ListValue
                        {
                            strMark = "$zzkb1",
                            strVal  = model1.ReferralOrg
                        });

                        list.Add(new ListValue
                        {
                            strMark = "$zzyy1",
                            strVal  = model1.ReferralReason
                        });

                        list.Add(new ListValue
                        {
                            strMark = "$zzjg1",
                            strVal  = model1.ReferralResult
                        });

                        list.Add(new ListValue
                        {
                            strMark = "$clyj1",
                            strVal  = model1.HandleView
                        });

                        list.Add(new ListValue
                        {
                            strMark = "$xcsfsj1",
                            strVal  = DrawItems.strToDate(model1.NextVisitDate)
                        });

                        list.Add(new ListValue
                        {
                            strMark = "$sfys1",
                            strVal  = model1.VisitDoctor
                        });
                        list.Add(new ListValue
                        {
                            strMark = "&qm1",
                            strVal  = string.Format("{0}{1}_1_{2}.png", SignPath, model2.IDCardNo, Convert.ToDateTime(model1.FollowupDate).ToString("yyyyMMdd"))
                        });
                        list.Add(new ListValue
                        {
                            strMark = "&sfys1",
                            strVal  = string.Format("{0}{1}_1_{2}_Doc.png", SignPath, model2.IDCardNo, Convert.ToDateTime(model1.FollowupDate).ToString("yyyyMMdd"))
                        });
                        //滕州无签字版
                        list.Add(new ListValue
                        {
                            strMark = "$qm1",
                            strVal  = model.CustomerName
                        });
                        list.Add(new ListValue
                        {
                            strMark = "$sfys1",
                            strVal  = model2.VisitDoctor
                        });
                    }

                    model1 = new ChronicLungerVisitBLL().GetModelByOutKey(model2.ID, "2");

                    if (model1 != null)
                    {
                        list.Add(new ListValue
                        {
                            strMark = "$sfrq2",
                            strVal  = DrawItems.strToDate(model1.FollowupDate)
                        });

                        list.Add(new ListValue
                        {
                            strMark = "$m2",
                            strVal  = DrawItems.objToNumStr(model1.CureMonth, 0)
                        });

                        list.Add(new ListValue
                        {
                            strMark = "#ddryxz2",
                            strVal  = model1.Supervisor
                        });

                        list.Add(new ListValue
                        {
                            strMark = "#sffs2",
                            strVal  = model1.FollowupWay
                        });

                        string strSymptom2 = "";
                        if (!string.IsNullOrEmpty(model1.Symptom))
                        {
                            foreach (string str in model1.Symptom.Split(new char[] { ',' }))
                            {
                                if (!string.IsNullOrEmpty(str))
                                {
                                    strSymptom2 += (int.Parse(str) - 1).ToString() + ",";
                                }
                            }
                            strSymptom2 = strSymptom2.Remove(strSymptom2.Length - 1);
                        }
                        list.Add(new ListValue
                        {
                            strMark = "#zz2",
                            strVal  = strSymptom2
                        });

                        list.Add(new ListValue
                        {
                            strMark = "%zzqt2",
                            strVal  = model1.SymptomEx
                        });

                        list.Add(new ListValue
                        {
                            strMark = "$y2",
                            strVal  = DrawItems.objToNumStr(model1.SmokeDayNum, 0)
                        });

                        list.Add(new ListValue
                        {
                            strMark = "$ny2",
                            strVal  = DrawItems.objToNumStr(model1.NextSmokeDayNum, 0)
                        });

                        list.Add(new ListValue
                        {
                            strMark = "$j2",
                            strVal  = DrawItems.objToNumStr(model1.DayDrinkVolume, 0)
                        });

                        list.Add(new ListValue
                        {
                            strMark = "$nj2",
                            strVal  = DrawItems.objToNumStr(model1.NextDayDrinkVolume, 0)
                        });

                        list.Add(new ListValue
                        {
                            strMark = "%hlfa2",
                            strVal  = model1.ChemotherapyScheme
                        });

                        list.Add(new ListValue
                        {
                            strMark = "#yf2",
                            strVal  = model1.MedicationCompliance
                        });

                        list.Add(new ListValue
                        {
                            strMark = "#ypjx2",
                            strVal  = model1.DrugType
                        });

                        list.Add(new ListValue
                        {
                            strMark = "$lfycs2",
                            strVal  = DrawItems.objToNumStr(model1.OmissiveTimes, 0)
                        });

                        list.Add(new ListValue
                        {
                            strMark = "#ywfy2",
                            strVal  = model1.Adr
                        });

                        list.Add(new ListValue
                        {
                            strMark = "$fy2",
                            strVal  = model1.AdrEx
                        });

                        list.Add(new ListValue
                        {
                            strMark = "#bfz2",
                            strVal  = model1.Complication
                        });

                        list.Add(new ListValue
                        {
                            strMark = "$hbz2",
                            strVal  = model1.ComplicationEx
                        });

                        list.Add(new ListValue
                        {
                            strMark = "$zzkb2",
                            strVal  = model1.ReferralOrg
                        });

                        list.Add(new ListValue
                        {
                            strMark = "$zzyy2",
                            strVal  = model1.ReferralReason
                        });

                        list.Add(new ListValue
                        {
                            strMark = "$zzjg2",
                            strVal  = model1.ReferralResult
                        });

                        list.Add(new ListValue
                        {
                            strMark = "$clyj2",
                            strVal  = model1.HandleView
                        });

                        list.Add(new ListValue
                        {
                            strMark = "$xcsfsj2",
                            strVal  = DrawItems.strToDate(model1.NextVisitDate)
                        });

                        list.Add(new ListValue
                        {
                            strMark = "$sfys2",
                            strVal  = model1.VisitDoctor
                        });
                        list.Add(new ListValue
                        {
                            strMark = "&qm2",
                            strVal  = string.Format("{0}{1}_2_{2}.png", SignPath, model2.IDCardNo, Convert.ToDateTime(model1.FollowupDate).ToString("yyyyMMdd"))
                        });
                        list.Add(new ListValue
                        {
                            strMark = "&sfys2",
                            strVal  = string.Format("{0}{1}_2_{2}_Doc.png", SignPath, model2.IDCardNo, Convert.ToDateTime(model1.FollowupDate).ToString("yyyyMMdd"))
                        });
                        //滕州无签字版
                        list.Add(new ListValue
                        {
                            strMark = "$qm2",
                            strVal  = model.CustomerName
                        });
                        list.Add(new ListValue
                        {
                            strMark = "$sfys2",
                            strVal  = model2.VisitDoctor
                        });
                    }

                    model1 = new ChronicLungerVisitBLL().GetModelByOutKey(model2.ID, "3");

                    if (model1 != null)
                    {
                        list.Add(new ListValue
                        {
                            strMark = "$sfrq3",
                            strVal  = DrawItems.strToDate(model1.FollowupDate)
                        });

                        list.Add(new ListValue
                        {
                            strMark = "$m3",
                            strVal  = DrawItems.objToNumStr(model1.CureMonth, 0)
                        });

                        list.Add(new ListValue
                        {
                            strMark = "#ddryxz3",
                            strVal  = model1.Supervisor
                        });

                        list.Add(new ListValue
                        {
                            strMark = "#sffs3",
                            strVal  = model1.FollowupWay
                        });

                        string strSymptom3 = "";
                        if (!string.IsNullOrEmpty(model1.Symptom))
                        {
                            foreach (string str in model1.Symptom.Split(new char[] { ',' }))
                            {
                                if (!string.IsNullOrEmpty(str))
                                {
                                    strSymptom3 += (int.Parse(str) - 1).ToString() + ",";
                                }
                            }
                            strSymptom3 = strSymptom3.Remove(strSymptom3.Length - 1);
                        }
                        list.Add(new ListValue
                        {
                            strMark = "#zz3",
                            strVal  = strSymptom3
                        });

                        list.Add(new ListValue
                        {
                            strMark = "%zzqt3",
                            strVal  = model1.SymptomEx
                        });

                        list.Add(new ListValue
                        {
                            strMark = "$y3",
                            strVal  = DrawItems.objToNumStr(model1.SmokeDayNum, 0)
                        });

                        list.Add(new ListValue
                        {
                            strMark = "$ny3",
                            strVal  = DrawItems.objToNumStr(model1.NextSmokeDayNum, 0)
                        });

                        list.Add(new ListValue
                        {
                            strMark = "$j3",
                            strVal  = DrawItems.objToNumStr(model1.DayDrinkVolume, 0)
                        });

                        list.Add(new ListValue
                        {
                            strMark = "$nj3",
                            strVal  = DrawItems.objToNumStr(model1.NextDayDrinkVolume, 0)
                        });

                        list.Add(new ListValue
                        {
                            strMark = "%hlfa3",
                            strVal  = model1.ChemotherapyScheme
                        });

                        list.Add(new ListValue
                        {
                            strMark = "#yf3",
                            strVal  = model1.MedicationCompliance
                        });

                        list.Add(new ListValue
                        {
                            strMark = "#ypjx3",
                            strVal  = model1.DrugType
                        });

                        list.Add(new ListValue
                        {
                            strMark = "$lfycs3",
                            strVal  = DrawItems.objToNumStr(model1.OmissiveTimes, 0)
                        });

                        list.Add(new ListValue
                        {
                            strMark = "#ywfy3",
                            strVal  = model1.Adr
                        });

                        list.Add(new ListValue
                        {
                            strMark = "$fy3",
                            strVal  = model1.AdrEx
                        });

                        list.Add(new ListValue
                        {
                            strMark = "#bfz3",
                            strVal  = model1.Complication
                        });

                        list.Add(new ListValue
                        {
                            strMark = "$hbz3",
                            strVal  = model1.ComplicationEx
                        });

                        list.Add(new ListValue
                        {
                            strMark = "$zzkb3",
                            strVal  = model1.ReferralOrg
                        });

                        list.Add(new ListValue
                        {
                            strMark = "$zzyy3",
                            strVal  = model1.ReferralReason
                        });

                        list.Add(new ListValue
                        {
                            strMark = "$zzjg3",
                            strVal  = model1.ReferralResult
                        });

                        list.Add(new ListValue
                        {
                            strMark = "$clyj3",
                            strVal  = model1.HandleView
                        });

                        list.Add(new ListValue
                        {
                            strMark = "$xcsfsj3",
                            strVal  = DrawItems.strToDate(model1.NextVisitDate)
                        });

                        list.Add(new ListValue
                        {
                            strMark = "$sfys3",
                            strVal  = model1.VisitDoctor
                        });
                        list.Add(new ListValue
                        {
                            strMark = "&qm3",
                            strVal  = string.Format("{0}{1}_3_{2}.png", SignPath, model2.IDCardNo, Convert.ToDateTime(model1.FollowupDate).ToString("yyyyMMdd"))
                        });
                        list.Add(new ListValue
                        {
                            strMark = "&sfys3",
                            strVal  = string.Format("{0}{1}_3_{2}_Doc.png", SignPath, model2.IDCardNo, Convert.ToDateTime(model1.FollowupDate).ToString("yyyyMMdd"))
                        });
                        //滕州无签字版
                        list.Add(new ListValue
                        {
                            strMark = "$qm3",
                            strVal  = model.CustomerName
                        });
                        list.Add(new ListValue
                        {
                            strMark = "$sfys3",
                            strVal  = model2.VisitDoctor
                        });
                    }
                    model1 = new ChronicLungerVisitBLL().GetModelByOutKey(model2.ID, "4");

                    if (model1 != null)
                    {
                        list.Add(new ListValue
                        {
                            strMark = "$sfrq4",
                            strVal  = DrawItems.strToDate(model1.FollowupDate)
                        });

                        list.Add(new ListValue
                        {
                            strMark = "$m4",
                            strVal  = DrawItems.objToNumStr(model1.CureMonth, 0)
                        });

                        list.Add(new ListValue
                        {
                            strMark = "#ddryxz4",
                            strVal  = model1.Supervisor
                        });

                        list.Add(new ListValue
                        {
                            strMark = "#sffs4",
                            strVal  = model1.FollowupWay
                        });

                        string strSymptom4 = "";
                        if (!string.IsNullOrEmpty(model1.Symptom))
                        {
                            foreach (string str in model1.Symptom.Split(new char[] { ',' }))
                            {
                                if (!string.IsNullOrEmpty(str))
                                {
                                    strSymptom4 += (int.Parse(str) - 1).ToString() + ",";
                                }
                            }
                            strSymptom4 = strSymptom4.Remove(strSymptom4.Length - 1);
                        }
                        list.Add(new ListValue
                        {
                            strMark = "#zz4",
                            strVal  = strSymptom4
                        });

                        list.Add(new ListValue
                        {
                            strMark = "%zzqt4",
                            strVal  = model1.SymptomEx
                        });

                        list.Add(new ListValue
                        {
                            strMark = "$y4",
                            strVal  = DrawItems.objToNumStr(model1.SmokeDayNum, 0)
                        });

                        list.Add(new ListValue
                        {
                            strMark = "$ny4",
                            strVal  = DrawItems.objToNumStr(model1.NextSmokeDayNum, 0)
                        });

                        list.Add(new ListValue
                        {
                            strMark = "$j4",
                            strVal  = DrawItems.objToNumStr(model1.DayDrinkVolume, 0)
                        });

                        list.Add(new ListValue
                        {
                            strMark = "$nj4",
                            strVal  = DrawItems.objToNumStr(model1.NextDayDrinkVolume, 0)
                        });

                        list.Add(new ListValue
                        {
                            strMark = "%hlfa4",
                            strVal  = model1.ChemotherapyScheme
                        });

                        list.Add(new ListValue
                        {
                            strMark = "#yf4",
                            strVal  = model1.MedicationCompliance
                        });

                        list.Add(new ListValue
                        {
                            strMark = "#ypjx4",
                            strVal  = model1.DrugType
                        });

                        list.Add(new ListValue
                        {
                            strMark = "$lfycs4",
                            strVal  = DrawItems.objToNumStr(model1.OmissiveTimes, 0)
                        });

                        list.Add(new ListValue
                        {
                            strMark = "#ywfy4",
                            strVal  = model1.Adr
                        });

                        list.Add(new ListValue
                        {
                            strMark = "$fy4",
                            strVal  = model1.AdrEx
                        });

                        list.Add(new ListValue
                        {
                            strMark = "#bfz4",
                            strVal  = model1.Complication
                        });

                        list.Add(new ListValue
                        {
                            strMark = "$hbz4",
                            strVal  = model1.ComplicationEx
                        });

                        list.Add(new ListValue
                        {
                            strMark = "$zzkb4",
                            strVal  = model1.ReferralOrg
                        });

                        list.Add(new ListValue
                        {
                            strMark = "$zzyy4",
                            strVal  = model1.ReferralReason
                        });

                        list.Add(new ListValue
                        {
                            strMark = "$zzjg4",
                            strVal  = model1.ReferralResult
                        });

                        list.Add(new ListValue
                        {
                            strMark = "$clyj4",
                            strVal  = model1.HandleView
                        });

                        list.Add(new ListValue
                        {
                            strMark = "$xcsfsj4",
                            strVal  = DrawItems.strToDate(model1.NextVisitDate)
                        });

                        list.Add(new ListValue
                        {
                            strMark = "$sfys4",
                            strVal  = model1.VisitDoctor
                        });

                        list.Add(new ListValue
                        {
                            strMark = "$cxtzsj",
                            strVal  = DrawItems.strToDate(model1.StopCureDate)
                        });

                        list.Add(new ListValue
                        {
                            strMark = "#tzyi",
                            strVal  = model1.StopCureReason
                        });

                        list.Add(new ListValue
                        {
                            strMark = "$yfscs",
                            strVal  = DrawItems.objToNumStr(model1.ShouldVisitTimes, 0)
                        });

                        list.Add(new ListValue
                        {
                            strMark = "$sjfscs",
                            strVal  = DrawItems.objToNumStr(model1.VisitTimes, 0)
                        });

                        list.Add(new ListValue
                        {
                            strMark = "$yfcs",
                            strVal  = DrawItems.objToNumStr(model1.ShouldPharmacyTimes, 0)
                        });

                        list.Add(new ListValue
                        {
                            strMark = "$sfcs",
                            strVal  = DrawItems.objToNumStr(model1.PharmacyTimes, 0)
                        });


                        list.Add(new ListValue
                        {
                            strMark = "$fyl",
                            strVal  = DrawItems.objToNumStr(model1.PharmacyRate, 2)
                        });

                        list.Add(new ListValue
                        {
                            strMark = "$pgys1",
                            strVal  = model1.EstimateDoctor
                        });
                        list.Add(new ListValue
                        {
                            strMark = "&qm4",
                            strVal  = string.Format("{0}{1}_4_{2}.png", SignPath, model2.IDCardNo, Convert.ToDateTime(model1.FollowupDate).ToString("yyyyMMdd"))
                        });
                        list.Add(new ListValue
                        {
                            strMark = "&sfys4",
                            strVal  = string.Format("{0}{1}_4_{2}_Doc.png", SignPath, model2.IDCardNo, Convert.ToDateTime(model1.FollowupDate).ToString("yyyyMMdd"))
                        });
                        //滕州无签字版
                        list.Add(new ListValue
                        {
                            strMark = "$qm4",
                            strVal  = model.CustomerName
                        });
                        list.Add(new ListValue
                        {
                            strMark = "$sfys4",
                            strVal  = model2.VisitDoctor
                        });
                    }
                }
            }

            return(DrawItems.setPage("printXps\\26肺结核患者随访服务记录表.xps", list));
        }
예제 #5
0
        public FixedDocumentSequence getReport()
        {
            List <ListValue> list = null;

            if (!string.IsNullOrEmpty(this.CardID))
            {
                RecordsBaseInfoModel model = new RecordsBaseInfoBLL().GetModel(this.CardID);

                list = new List <ListValue>
                {
                    new ListValue
                    {
                        strMark = "$archiveid",
                        strVal  = model.RecordID
                    },
                    new ListValue
                    {
                        strMark = "$name",
                        strVal  = model.CustomerName
                    }
                };

                ChronicLungerFirstVisitModel model2 = new ChronicLungerFirstVisitBLL().GetModel(this.CardID);

                if (model2 != null)
                {
                    list.Add(new ListValue
                    {
                        strMark = "$sfrq",
                        strVal  = DrawItems.strToDate(model2.FollowupDate)
                    });

                    list.Add(new ListValue
                    {
                        strMark = "#sffs",
                        strVal  = model2.FollowupWay
                    });

                    list.Add(new ListValue
                    {
                        strMark = "#hzlx",
                        strVal  = model2.PatientType
                    });

                    list.Add(new ListValue
                    {
                        strMark = "#tjqk",
                        strVal  = model2.Sputumfungs
                    });

                    list.Add(new ListValue
                    {
                        strMark = "#nyqk",
                        strVal  = model2.DrugFast
                    });
                    string strSymptom = "";
                    if (!string.IsNullOrEmpty(model2.Symptom))
                    {
                        foreach (string str in model2.Symptom.Split(new char[] { ',' }))
                        {
                            if (!string.IsNullOrEmpty(str))
                            {
                                strSymptom += (int.Parse(str) - 1).ToString() + ",";
                            }
                        }
                        strSymptom = strSymptom.Remove(strSymptom.Length - 1);
                    }
                    list.Add(new ListValue
                    {
                        strMark = "#zz",
                        strVal  = strSymptom
                    });

                    list.Add(new ListValue
                    {
                        strMark = "%zzqt",
                        strVal  = model2.SymptomEx
                    });

                    list.Add(new ListValue
                    {
                        strMark = "$hlfa",
                        strVal  = model2.ChemotherapyScheme
                    });

                    list.Add(new ListValue
                    {
                        strMark = "#yf",
                        strVal  = model2.MedicationCompliance
                    });

                    list.Add(new ListValue
                    {
                        strMark = "#ypjx",
                        strVal  = model2.DrugType
                    });

                    list.Add(new ListValue
                    {
                        strMark = "#ddryxz",
                        strVal  = model2.Supervisor
                    });

                    list.Add(new ListValue
                    {
                        strMark = "#ddjs",
                        strVal  = model2.StandaloneRoom
                    });

                    list.Add(new ListValue
                    {
                        strMark = "#tfqk",
                        strVal  = model2.Ventilation
                    });

                    list.Add(new ListValue
                    {
                        strMark = "$xy",
                        strVal  = DrawItems.objToNumStr(model2.SmokeDayNum, 0)
                    });

                    list.Add(new ListValue
                    {
                        strMark = "$nxy",
                        strVal  = DrawItems.objToNumStr(model2.NextSmokeDayNum, 0)
                    });

                    list.Add(new ListValue
                    {
                        strMark = "$yj",
                        strVal  = DrawItems.objToNumStr(model2.DayDrinkVolume, 0)
                    });

                    list.Add(new ListValue
                    {
                        strMark = "$nyj",
                        strVal  = DrawItems.objToNumStr(model2.NextDayDrinkVolume, 0)
                    });

                    list.Add(new ListValue
                    {
                        strMark = "$qydd",
                        strVal  = model2.MediclineReceivePlace
                    });

                    list.Add(new ListValue
                    {
                        strMark = "$qysj",
                        strVal  = DrawItems.strToDate(model2.MediclineReceiveTime)
                    });

                    list.Add(new ListValue
                    {
                        strMark = "#jkjy1",
                        strVal  = model2.RecordcardWrite
                    });

                    list.Add(new ListValue
                    {
                        strMark = "#jkjy2",
                        strVal  = model2.PharmacyWayDeposit
                    });

                    list.Add(new ListValue
                    {
                        strMark = "#jkjy3",
                        strVal  = model2.Therapies
                    });

                    list.Add(new ListValue
                    {
                        strMark = "#jkjy4",
                        strVal  = model2.IndisciplineHarm
                    });

                    list.Add(new ListValue
                    {
                        strMark = "#jkjy5",
                        strVal  = model2.AdrsHandle
                    });

                    list.Add(new ListValue
                    {
                        strMark = "#jkjy6",
                        strVal  = model2.SubsequentVisit
                    });

                    list.Add(new ListValue
                    {
                        strMark = "#jkjy7",
                        strVal  = model2.InsistPharmacy
                    });

                    list.Add(new ListValue
                    {
                        strMark = "#jkjy8",
                        strVal  = model2.LivingHabit
                    });

                    list.Add(new ListValue
                    {
                        strMark = "#jkjy9",
                        strVal  = model2.ChecktouchPerson
                    });

                    list.Add(new ListValue
                    {
                        strMark = "$xcsfsj",
                        strVal  = DrawItems.strToDate(model2.NextVisitDate)
                    });
                    list.Add(new ListValue
                    {
                        strMark = "&qm",
                        strVal  = string.Format("{0}{1}_{2}.png", SignPath, model2.IDCardNo, Convert.ToDateTime(model2.FollowupDate).ToString("yyyyMMdd"))
                    });
                    list.Add(new ListValue
                    {
                        strMark = "&sfys",
                        strVal  = string.Format("{0}{1}_{2}_Doc.png", SignPath, model2.IDCardNo, Convert.ToDateTime(model2.FollowupDate).ToString("yyyyMMdd"))
                    });
                    //滕州无签字版
                    list.Add(new ListValue
                    {
                        strMark = "$qm",
                        strVal  = model.CustomerName
                    });
                    list.Add(new ListValue
                    {
                        strMark = "$sfys",
                        strVal  = model2.VisitDoctor
                    });
                }
            }

            return(DrawItems.setPage("printXps\\25肺结核患者第一次入户随访记录表.xps", list));
        }
예제 #6
0
 public static List <ListValue> lsCheck(string val, string mark, int k)
 {
     return(DrawItems.lsCheck(val, "", mark, k));
 }
예제 #7
0
        public static UIElement ReplaceMark(Glyphs gps, List <ListValue> dicVal)
        {
            StructMark Mk        = DrawItems.ExplodeMark(gps);
            double     fontSize  = Mk.fontSize;
            double     orgX      = Mk.x;
            double     y         = Mk.y;
            UIElement  result    = new UIElement();
            ListValue  listValue = new ListValue();

            listValue = (
                from m in dicVal
                where m.strMark == Mk.val.Trim()
                select m).FirstOrDefault <ListValue>();
            if (listValue == null)
            {
                listValue         = new ListValue();
                listValue.strMark = Mk.val;
                listValue.strVal  = "";
            }
            else
            {
                if (listValue.strVal == null)
                {
                    listValue.strVal = "";
                }
            }
            if (Mk.val.Contains("archiveid"))
            {
                if (listValue.strType == "1")
                {
                    result = DrawItems.CreatArchiveid(listValue.strVal, orgX, y, fontSize);
                }
                else
                {
                    result = DrawItems.CreatShortArchiveid(listValue.strVal, orgX, y, fontSize);
                }
            }
            else
            {
                if (Mk.type == "#")
                {
                    result = DrawItems.CreatCheck(listValue.strVal, orgX, y, fontSize, Mk.len);
                }
                else
                {
                    if (Mk.type == "!")
                    {
                        result = DrawItems.CreatDate(listValue.strVal, orgX, y, fontSize);
                    }
                    else
                    {
                        if (Mk.type == "%")
                        {
                            result = DrawItems.CreatGlyphs(listValue.strVal, orgX, y, fontSize, Mk.width, Mk.height);
                        }
                        else if (Mk.type == "^")
                        {
                            result = DrawItems.CreatTitleGlyphs(listValue.strVal, orgX, y, fontSize);
                        }
                        else
                        {
                            if (Mk.type == "@")
                            {
                                if (listValue.strVal == "1")
                                {
                                    result = DrawItems.DrawCheck(orgX, y, 20.0);
                                }
                            }
                            else if (Mk.type == "&")
                            {
                                if (Mk.val.Contains("photo"))
                                {
                                    result = DrawItems.DrawImagePhoto(listValue.strVal, orgX, y);
                                }
                                else if (Mk.val.Contains("bchao"))
                                {
                                    result = DrawItems.DrawImageBChao(listValue.strVal, orgX, y);
                                }
                                else if (Mk.val.Contains("ecg"))
                                {
                                    result = DrawItems.DrawImageEcg(listValue.strVal, orgX, y);
                                }
                                else
                                {
                                    result = DrawItems.DrawImage(listValue.strVal, orgX, y);
                                }
                            }
                            else
                            {
                                if (Mk.locat == "E")
                                {
                                    int length = listValue.strVal.Length;
                                    orgX = Mk.x - (double)length * fontSize / 2.0;
                                }
                                //result = DrawItems.CreatGlyphs(listValue.strVal, orgX, y, fontSize, false, Mk.len, false);
                                result = DrawItems.CreatGlyphs(listValue.strVal, orgX, y, fontSize, false, listValue.strVal.Length, false);
                            }
                        }
                    }
                }
            }
            return(result);
        }
예제 #8
0
 public static TextBlock CreatGlyphs(string strVal, double orgX, double orgY, double fontSize)
 {
     return(DrawItems.CreatGlyphs(strVal, orgX, orgY, fontSize, false, 30, false));
 }