public override void ToXml(XElement document) { ThrombocytopeniaProfileV2TestOrder panelSetOrder = (ThrombocytopeniaProfileV2TestOrder)this.m_AccessionOrder.PanelSetOrderCollection.GetPanelSetOrder(this.m_ReportNo); this.AddHeader(document, panelSetOrder, "Thrombocytopenia Profile"); this.AddNextObxElement("", document, "F"); this.AddNextObxElement("Test: Anti-Platelet Antibody - IgG", document, "F"); this.AddNextObxElement("Result: " + panelSetOrder.AntiPlateletAntibodyIgG, document, "F"); this.AddNextObxElement("Reference: " + panelSetOrder.AntiPlateletAntibodyIgGReference, document, "F"); this.AddNextObxElement("", document, "F"); this.AddNextObxElement("Test: Anti-Platelet Antibody - IgM", document, "F"); this.AddNextObxElement("Result: " + panelSetOrder.AntiPlateletAntibodyIgM, document, "F"); this.AddNextObxElement("Reference: " + panelSetOrder.AntiPlateletAntibodyIgMReference, document, "F"); this.AddNextObxElement("", document, "F"); if (string.IsNullOrEmpty(panelSetOrder.ReticulatedPlateletAnalysis) == false) { this.AddNextObxElement("Test: Reticulated Platelet Analysis", document, "F"); this.AddNextObxElement("Result: " + panelSetOrder.ReticulatedPlateletAnalysis, document, "F"); this.AddNextObxElement("Reference Range: " + panelSetOrder.ReticulatedPlateletAnalysisReference, document, "F"); this.AddNextObxElement("", document, "F"); } this.AddAmendments(document); YellowstonePathology.Business.Specimen.Model.SpecimenOrder specimenOrder = this.m_AccessionOrder.SpecimenOrderCollection.GetSpecimenOrder(panelSetOrder.OrderedOn, panelSetOrder.OrderedOnId); this.AddNextObxElement("Specimen Description: " + specimenOrder.Description, document, "F"); this.AddNextObxElement("", document, "F"); this.AddNextObxElement("Method", document, "F"); this.HandleLongString(panelSetOrder.Method, document, "F"); this.AddNextObxElement("", document, "F"); this.AddNextObxElement("Interpretation:", document, "F"); this.HandleLongString(panelSetOrder.Interpretation, document, "F"); this.AddNextObxElement("", document, "F"); this.HandleLongString(panelSetOrder.ASRComment, document, "F"); this.AddNextObxElement("", document, "F"); string locationPerformed = panelSetOrder.GetLocationPerformedComment(); this.AddNextObxElement(locationPerformed, document, "F"); this.AddNextObxElement(string.Empty, document, "F"); }
public override void Render() { this.m_TemplateName = @"\\CFileServer\Documents\ReportTemplates\XmlTemplates\ThrombocytopeniaProfileV2.xml"; base.OpenTemplate(); this.SetDemographicsV2(); this.SetReportDistribution(); this.SetCaseHistory(); ThrombocytopeniaProfileV2TestOrder testOrder = (ThrombocytopeniaProfileV2TestOrder)this.m_PanelSetOrder; YellowstonePathology.Business.Amendment.Model.AmendmentCollection amendmentCollection = this.m_AccessionOrder.AmendmentCollection.GetAmendmentsForReport(testOrder.ReportNo); YellowstonePathology.Business.Document.AmendmentSection amendment = new YellowstonePathology.Business.Document.AmendmentSection(); amendment.SetAmendment(amendmentCollection, this.m_ReportXml, this.m_NameSpaceManager, true); YellowstonePathology.Business.Specimen.Model.SpecimenOrder specimenOrder = this.m_AccessionOrder.SpecimenOrderCollection.GetSpecimenOrder(testOrder.OrderedOn, testOrder.OrderedOnId); this.SetXmlNodeData("specimen_description", specimenOrder.Description); string collectionDateTimeString = YellowstonePathology.Business.Helper.DateTimeExtensions.CombineDateAndTime(specimenOrder.CollectionDate, specimenOrder.CollectionTime); this.SetXmlNodeData("date_time_collected", collectionDateTimeString); this.SetXmlNodeData("apa_igg", testOrder.AntiPlateletAntibodyIgG); this.SetXmlNodeData("apa_igm", testOrder.AntiPlateletAntibodyIgM); this.SetXmlNodeData("apa_igg_reference", testOrder.AntiPlateletAntibodyIgGReference); if (string.IsNullOrEmpty(testOrder.ReticulatedPlateletAnalysis) == false) { this.SetXmlNodeData("r_p_a", testOrder.ReticulatedPlateletAnalysis); this.SetXmlNodeData("r_p_a_reference", testOrder.ReticulatedPlateletAnalysisReference); } else { this.DeleteRow("r_p_a"); } this.SetXmlNodeData("apa_igm_reference", testOrder.AntiPlateletAntibodyIgMReference); this.SetXMLNodeParagraphData("report_interpretation", testOrder.Interpretation); this.SetXMLNodeParagraphData("report_method", testOrder.Method); this.SetXmlNodeData("asr_comment", testOrder.ASRComment); this.SaveReport(); }