Beispiel #1
0
        public void m_mthGetPrintContentFromDB(string reportGroupID, string applicationId, bool blnConfirmed)
        {
            try
            {
                clsPrintValuePara clsPrintValuePara = null;
                clsReportObject   clsReportObject   = null;
                lisprintBiz       biz = new lisprintBiz();

                long num = biz.m_lngGetReportObject(null, applicationId, out clsReportObject);

                if (clsReportObject != null && clsReportObject.bytReportObjectArr != null)
                {
                    Stream     stream    = new MemoryStream(clsReportObject.bytReportObjectArr);
                    IFormatter formatter = new BinaryFormatter();
                    clsPrintValuePara = (formatter.Deserialize(stream) as clsPrintValuePara);
                    stream.Close();
                }
                if (clsPrintValuePara == null)
                {
                    biz.m_lngGetReportPrintInfo(reportGroupID, applicationId, blnConfirmed, out clsPrintValuePara);
                }
                if (clsPrintValuePara != null)
                {
                    this.m_strReportGroupID = reportGroupID;
                    this.m_ObjPrintInfo     = clsPrintValuePara;
                }
            }
            catch (Exception ex)
            {
                //new clsLogText().LogError(ex.Message);
                ExceptionLog.OutPutException("m_mthGetPrintContentFromDB-->" + ex);
            }
        }
Beispiel #2
0
        void Query()
        {
            clsDomainController_ApplicationManage clsDomainController_ApplicationManage = new clsDomainController_ApplicationManage();
            clsDomainController_ApplicationManage clsDCApp = clsDomainController_ApplicationManage;

            string deptStr            = string.Empty;
            string dteStart           = string.Empty;
            string dteEnd             = string.Empty;
            string ipNo               = string.Empty;
            List <entityLisInfo> data = new List <entityLisInfo>();

            try
            {
                lisprintBiz biz       = new lisprintBiz();
                string      beginDate = this.dteDateStart.Text.Trim();
                string      endDate   = this.dteDateEnd.Text.Trim();

                if (string.IsNullOrEmpty(this.txtCardNo.Text))
                {
                    DialogBox.Msg("请输入卡号或住院号。");
                    return;
                }

                //this.gcData.DataSource = biz.QueryAreaReport(beginDate, endDate, this.txtCardNo.Text);
            }
            catch (Exception objEx)
            {
                ExceptionLog.OutPutException("Query-->" + objEx);
            }
        }
        public static long m_lngGetCollocate(out string p_strFlag, string p_strSetID)
        {
            p_strFlag = null;
            IPrincipal  p_objPrincipal = null;
            lisprintBiz biz            = new lisprintBiz();

            return(biz.m_lngGetCollocate(p_objPrincipal, out p_strFlag, p_strSetID));
        }
Beispiel #4
0
        /// <summary>
        ///
        /// </summary>
        void QueryAndPrint()
        {
            string   deptStr   = string.Empty;
            string   dteStart  = string.Empty;
            string   dteEnd    = string.Empty;
            string   ipNo      = string.Empty;
            string   patName   = string.Empty;
            int      printed   = 0;
            int      unPrinted = 0;
            DateTime dtmNow    = DateTime.Now;

            try
            {
                uiHelper.BeginLoading(this);
                lisprintBiz biz       = new lisprintBiz();
                int         daySpan   = 0 - Function.Int(ReadXmlConfig("Dayspan"));
                string      beginDate = dtmNow.AddDays(daySpan).ToString("yyyy-MM-dd");
                string      endDate   = dtmNow.ToString("yyyy-MM-dd");
                String      cardNo    = this.txtCard.Text;
                if (cardNo.Length < 10)
                {
                    cardNo = cardNo.PadLeft(10, '0');
                }
                if (string.IsNullOrEmpty(this.txtCard.Text))
                {
                    messageShow(0, "请输入卡号。");
                    return;
                }
                patName = biz.getPatName(cardNo);
                data    = biz.QueryReport(beginDate, endDate, cardNo, ref printed, ref unPrinted);

                if (printed == -1)
                {
                    messageShow(0, "对不起,系统有故障。\r\n如有疑问,请到检验科咨询!");
                    return;
                }

                if (data == null || data.Count <= 0)
                {
                    messageShow(0, patName + ",未查询到您的报告。\r\n如有疑问,请到检验科咨询!");
                }
                else if (data != null && data.Count > 0)
                {
                    if (data.Count == printed)
                    {
                        messageShow(0, patName + ",未查询到您的报告。\r\n如有疑问,请到检验科咨询!");
                    }
                    else
                    {
                        printInit();
                        int    Ii   = 0;
                        string tip1 = patName + "," + unPrinted.ToString();
                        messageShow(1, tip1);
                        foreach (entityLisInfo var in data)
                        {
                            if (string.IsNullOrEmpty(var.printeded) || var.printeded == "0")
                            {
                                messageShow(2, (++Ii).ToString());
                                this.Print(var.rptGroupId, var.applicationId);
                                Delay(waitTime);
                            }
                            if (string.IsNullOrEmpty(var.checkContent))
                            {
                                if (var.checkContent.Contains("性激素6项") && var.checkContent.Contains("绒毛膜促性腺激素定量"))
                                {
                                    messageShow(2, (++Ii).ToString());
                                    Delay(waitTime);
                                }
                            }
                        }
                        printCompleted();
                        messageShow(3, "您的报告已全部打印。");
                        Delay(3);
                        this.lblComplete.Text = string.Empty;
                    }
                }
            }
            catch (Exception objEx)
            {
                ExceptionLog.OutPutException("Query-->" + objEx);
                messageShow(0, "对不起,系统有故障!如有疑问,请到检验科咨询!");
            }
            finally
            {
                uiHelper.CloseLoading(this);
            }
        }
Beispiel #5
0
        public long m_mthWriteReportPrintState(string p_strApplicaionID)
        {
            lisprintBiz biz = new lisprintBiz();

            return(biz.m_lngUpdatePrinctTime(null, p_strApplicaionID));
        }