コード例 #1
0
        public static PNHResult GetResult(PNHTestOrder pnhTestOrder, YellowstonePathology.Business.Test.AccessionOrder accessionOrder)
        {
            PNHResult result = new PNHResult();
            List<YellowstonePathology.Business.Test.AccessionOrder> accessionOrders = result.GetPreviousAccessions(accessionOrder.PatientId);

            result.SetTotals(pnhTestOrder);

            if (result.IsNegativeWithPreviousPositiveResult(accessionOrders, pnhTestOrder.MasterAccessionNo, pnhTestOrder.OrderDate.Value) == true)
            {
                result = new PNHNegativeWithPreviousPositiveResult();
            }
            else if (result.IsPersistentResult(accessionOrders, pnhTestOrder.MasterAccessionNo, pnhTestOrder.OrderDate.Value) == true)
            {
                result = new PNHPersistentPositiveResult();
            }
            else if (result.IsNegativeResult == true)
            {
                result = new PNHNegativeResult();
            }
            else if (result.IsSmallPositiveResult == true)
            {
                result = new PNHSmallPositiveResult();
            }
            else if (result.IsSignificantPositiveResult == true)
            {
                result = new PNHSignificantPositiveResult();
            }
            else if (result.IsGpiDeficientResult == true)
            {
                result = new PNHGpiDeficientResult();
            }
            result.SetTotals(pnhTestOrder);
            return result;
        }
コード例 #2
0
        public static PNHResult GetResult(PNHTestOrder pnhTestOrder, YellowstonePathology.Business.Test.AccessionOrder accessionOrder)
        {
            PNHResult result = new PNHResult();
            List <YellowstonePathology.Business.Test.AccessionOrder> accessionOrders = result.GetPreviousAccessions(accessionOrder.PatientId);

            result.SetTotals(pnhTestOrder);

            if (result.IsNegativeWithPreviousPositiveResult(accessionOrders, pnhTestOrder.MasterAccessionNo, pnhTestOrder.OrderDate.Value) == true)
            {
                result = new PNHNegativeWithPreviousPositiveResult();
            }
            else if (result.IsPersistentResult(accessionOrders, pnhTestOrder.MasterAccessionNo, pnhTestOrder.OrderDate.Value) == true)
            {
                result = new PNHPersistentPositiveResult();
            }
            else if (result.IsNegativeResult == true)
            {
                result = new PNHNegativeResult();
            }
            else if (result.IsSmallPositiveResult == true)
            {
                result = new PNHSmallPositiveResult();
            }
            else if (result.IsSignificantPositiveResult == true)
            {
                result = new PNHSignificantPositiveResult();
            }
            else if (result.IsGpiDeficientResult == true)
            {
                result = new PNHGpiDeficientResult();
            }
            result.SetTotals(pnhTestOrder);
            return(result);
        }
コード例 #3
0
ファイル: PNHEpicObxView.cs プロジェクト: ericramses/YPILIS
        public override void ToXml(XElement document)
        {
            PNHTestOrder testOrder = (PNHTestOrder)this.m_AccessionOrder.PanelSetOrderCollection.GetPanelSetOrder(this.m_ReportNo);

            PNHNegativeResult pnhNegativeResult = new PNHNegativeResult();
            if (testOrder.ResultCode == pnhNegativeResult.ResultCode)
            {
                this.NegativeToXml(document, testOrder);
            }
            else
            {
                this.PositiveToXml(document, testOrder);
            }
        }
コード例 #4
0
ファイル: PNHEpicObxView.cs プロジェクト: ericramses/YPILIS
        public override void ToXml(XElement document)
        {
            PNHTestOrder testOrder = (PNHTestOrder)this.m_AccessionOrder.PanelSetOrderCollection.GetPanelSetOrder(this.m_ReportNo);


            PNHNegativeResult pnhNegativeResult = new PNHNegativeResult();

            if (testOrder.ResultCode == pnhNegativeResult.ResultCode)
            {
                this.NegativeToXml(document, testOrder);
            }
            else
            {
                this.PositiveToXml(document, testOrder);
            }
        }
コード例 #5
0
ファイル: PNHCMMCNTEView.cs プロジェクト: ericramses/YPILIS
        public override void ToXml(XElement document)
        {
            PNHTestOrder testOrder = (PNHTestOrder)this.m_AccessionOrder.PanelSetOrderCollection.GetPanelSetOrder(this.m_ReportNo);
            PNHNegativeResult pnhNegativeResult = new PNHNegativeResult();
            this.AddCompanyHeader(document);
            this.AddBlankNteElement(document);
            this.AddNextNteElement("PNH, Highly Sensitive(FLAER)", document);
            this.AddNextNteElement("Master Accession #: " + testOrder.MasterAccessionNo, document);
            this.AddNextNteElement("Report #: " + testOrder.ReportNo, document);
            this.AddBlankNteElement(document);

            if (testOrder.ResultCode == pnhNegativeResult.ResultCode)
            {
                this.NegativeToXml(document, testOrder);
            }
            else
            {
                this.PositiveToXml(document, testOrder);
            }
        }
コード例 #6
0
ファイル: PNHCMMCNTEView.cs プロジェクト: ericramses/YPILIS
        public override void ToXml(XElement document)
        {
            PNHTestOrder      testOrder         = (PNHTestOrder)this.m_AccessionOrder.PanelSetOrderCollection.GetPanelSetOrder(this.m_ReportNo);
            PNHNegativeResult pnhNegativeResult = new PNHNegativeResult();

            this.AddCompanyHeader(document);
            this.AddBlankNteElement(document);
            this.AddNextNteElement("PNH, Highly Sensitive(FLAER)", document);
            this.AddNextNteElement("Master Accession #: " + testOrder.MasterAccessionNo, document);
            this.AddNextNteElement("Report #: " + testOrder.ReportNo, document);
            this.AddBlankNteElement(document);

            if (testOrder.ResultCode == pnhNegativeResult.ResultCode)
            {
                this.NegativeToXml(document, testOrder);
            }
            else
            {
                this.PositiveToXml(document, testOrder);
            }
        }
コード例 #7
0
ファイル: PNHWordDocument.cs プロジェクト: waffle-iron/YPILIS
        public override void Render()
        {
            PNHTestOrder testOrder = (PNHTestOrder)this.m_PanelSetOrder;

            if (string.IsNullOrEmpty(testOrder.ResultCode) == true)
            {
                System.Windows.MessageBox.Show("Unable to create report. Template is not selected");
                return;
            }

            PNHNegativeResult pnhNegativeResult = new PNHNegativeResult();

            if (testOrder.ResultCode == pnhNegativeResult.ResultCode)
            {
                this.m_TemplateName = @"\\CFileServer\Documents\ReportTemplates\XmlTemplates\PNHAnalysisNegative.8.xml";
            }
            else
            {
                this.m_TemplateName = @"\\CFileServer\Documents\ReportTemplates\XmlTemplates\PNHAnalysisPositive.8.xml";
            }


            this.OpenTemplate();

            //setting date of service to date only
            if (this.m_AccessionOrder.CollectionDate.HasValue)
            {
                this.ReplaceText("collection_date", this.m_AccessionOrder.CollectionDate.Value.ToShortDateString());
            }

            this.SetDemographicsV2();
            this.SetReportDistribution();
            this.SetCaseHistory();

            if (this.m_PanelSetOrder.Final)
            {
                this.ReplaceText("pathologist_signature", this.m_PanelSetOrder.Signature);
            }

            this.SetXmlNodeData("report_result", testOrder.Result);

            YellowstonePathology.Business.Specimen.Model.SpecimenOrder specimenOrder = this.m_AccessionOrder.SpecimenOrderCollection.GetSpecimenOrder(this.m_PanelSetOrder.OrderedOn, this.m_PanelSetOrder.OrderedOnId);
            this.SetXmlNodeData("specimen_description", specimenOrder.Description);

            string collectionDateTimeString = YellowstonePathology.Business.Helper.DateTimeExtensions.CombineDateAndTime(specimenOrder.CollectionDate, specimenOrder.CollectionTime);

            this.SetXmlNodeData("date_time_collected", collectionDateTimeString);

            //Handle result type
            if (testOrder.ResultCode != pnhNegativeResult.ResultCode)
            {
                this.HandleResultMonitor(testOrder.ResultCode);
            }

            this.ReplaceText("report_comment", testOrder.Comment);
            this.ReplaceText("report_method", testOrder.Method);
            this.ReplaceText("report_references", testOrder.References);
            this.ReplaceText("asr_comment", testOrder.ASRComment);


            YellowstonePathology.Business.Document.AmendmentSection amendment = new YellowstonePathology.Business.Document.AmendmentSection();
            amendment.SetAmendment(m_PanelSetOrder.AmendmentCollection, this.m_ReportXml, this.m_NameSpaceManager, true);

            this.SaveReport();
        }
コード例 #8
0
ファイル: PNHWordDocument.cs プロジェクト: ericramses/YPILIS
        public override void Render()
        {
            PNHTestOrder testOrder = (PNHTestOrder)this.m_PanelSetOrder;

            if (string.IsNullOrEmpty(testOrder.ResultCode) == true)
            {
                System.Windows.MessageBox.Show("Unable to create report. Template is not selected");
                return;
            }

            PNHNegativeResult pnhNegativeResult = new PNHNegativeResult();
            if (testOrder.ResultCode == pnhNegativeResult.ResultCode)
            {
                this.m_TemplateName = @"\\CFileServer\Documents\ReportTemplates\XmlTemplates\PNHAnalysisNegative.9.xml";
            }
            else
            {
                this.m_TemplateName = @"\\CFileServer\Documents\ReportTemplates\XmlTemplates\PNHAnalysisPositive.9.xml";
            }

            this.OpenTemplate();

            //setting date of service to date only
            if (this.m_AccessionOrder.CollectionDate.HasValue)
            {
                this.ReplaceText("collection_date", this.m_AccessionOrder.CollectionDate.Value.ToShortDateString());
            }

            this.SetDemographicsV2();
            this.SetReportDistribution();
            this.SetCaseHistory();

            if (this.m_PanelSetOrder.Final)
            {
                this.ReplaceText("pathologist_signature", this.m_PanelSetOrder.Signature);
            }

            this.SetXmlNodeData("report_result", testOrder.Result);

            YellowstonePathology.Business.Specimen.Model.SpecimenOrder specimenOrder = this.m_AccessionOrder.SpecimenOrderCollection.GetSpecimenOrder(this.m_PanelSetOrder.OrderedOn, this.m_PanelSetOrder.OrderedOnId);
            this.SetXmlNodeData("specimen_description", specimenOrder.Description);

            string collectionDateTimeString = YellowstonePathology.Business.Helper.DateTimeExtensions.CombineDateAndTime(specimenOrder.CollectionDate, specimenOrder.CollectionTime);
            this.SetXmlNodeData("date_time_collected", collectionDateTimeString);

            //Handle result type
            if (testOrder.ResultCode != pnhNegativeResult.ResultCode)
            {
                this.HandleResultMonitor(testOrder.ResultCode);
            }

            this.ReplaceText("report_result", testOrder.Result);
            this.ReplaceText("report_comment", testOrder.Comment);
            this.ReplaceText("report_method", testOrder.Method);
            this.ReplaceText("report_references", testOrder.ReportReferences);
            this.ReplaceText("asr_comment", testOrder.ASRComment);

            YellowstonePathology.Business.Document.AmendmentSection amendment = new YellowstonePathology.Business.Document.AmendmentSection();
            amendment.SetAmendment(m_PanelSetOrder.AmendmentCollection, this.m_ReportXml, this.m_NameSpaceManager, true);

            this.SaveReport();
        }