예제 #1
0
        private XmlNode SetStains(XmlNode tableNodeSS,
                                  XmlNode rowStainHeaderNode,
                                  XmlNode rowTestHeaderNode,
                                  XmlNode insertAfterRowSS,
                                  XmlNode rowSpecialStainNode,
                                  SurgicalSpecimen surgicalSpecimen,
                                  YellowstonePathology.Business.SpecialStain.StainResultItemCollection stainResultCollection)
        {
            XmlNode rowStainHeaderNodeClone = rowStainHeaderNode.Clone();

            tableNodeSS.InsertAfter(rowStainHeaderNodeClone, insertAfterRowSS);
            insertAfterRowSS = rowStainHeaderNodeClone;

            XmlNode rowTestHeaderNodeClone = rowTestHeaderNode.Clone();

            tableNodeSS.InsertAfter(rowTestHeaderNodeClone, insertAfterRowSS);
            insertAfterRowSS = rowTestHeaderNodeClone;

            foreach (YellowstonePathology.Business.SpecialStain.StainResultItem stainResultItem in stainResultCollection)
            {
                XmlNode rowSpecialStainClone = rowSpecialStainNode.Clone();
                string  stainDescription     = stainResultItem.ProcedureName;
                string  stainResult          = stainResultItem.Result;

                if (string.IsNullOrEmpty(stainResult) == true)
                {
                    stainResult = "Pending";
                }
                else if (stainResult.ToUpper() == "SEE COMMENT")
                {
                    stainResult = stainResultItem.ReportComment;
                }
                else
                {
                    string specialStainReportComment = stainResultItem.ReportComment;

                    if (!string.IsNullOrEmpty(specialStainReportComment))
                    {
                        stainResult += " - " + specialStainReportComment;
                    }
                }

                rowSpecialStainClone.SelectSingleNode("descendant::w:r[w:t='stain_description']/w:t", this.m_NameSpaceManager).InnerText = stainDescription;
                rowSpecialStainClone.SelectSingleNode("descendant::w:r[w:t='stain_result']/w:t", this.m_NameSpaceManager).InnerText      = stainResult;

                string block = surgicalSpecimen.GetBlockFromTestOrderId(stainResultItem.TestOrderId);
                rowSpecialStainClone.SelectSingleNode("descendant::w:r[w:t='block_description']/w:t", this.m_NameSpaceManager).InnerText = block;

                tableNodeSS.InsertAfter(rowSpecialStainClone, insertAfterRowSS);
                insertAfterRowSS = rowSpecialStainClone;
            }

            return(insertAfterRowSS);
        }
예제 #2
0
        private XmlNode SetStains(XmlNode tableNodeSS,
			XmlNode rowStainHeaderNode,
			XmlNode rowTestHeaderNode,
			XmlNode insertAfterRowSS,
			XmlNode rowSpecialStainNode,
			SurgicalSpecimen surgicalSpecimen,
			YellowstonePathology.Business.SpecialStain.StainResultItemCollection stainResultCollection)
        {
            XmlNode rowStainHeaderNodeClone = rowStainHeaderNode.Clone();
            tableNodeSS.InsertAfter(rowStainHeaderNodeClone, insertAfterRowSS);
            insertAfterRowSS = rowStainHeaderNodeClone;

            XmlNode rowTestHeaderNodeClone = rowTestHeaderNode.Clone();
            tableNodeSS.InsertAfter(rowTestHeaderNodeClone, insertAfterRowSS);
            insertAfterRowSS = rowTestHeaderNodeClone;

            foreach (YellowstonePathology.Business.SpecialStain.StainResultItem stainResultItem in stainResultCollection)
            {
                XmlNode rowSpecialStainClone = rowSpecialStainNode.Clone();
                string stainDescription = stainResultItem.ProcedureName;
                string stainResult = stainResultItem.Result;

                if (string.IsNullOrEmpty(stainResult) == true)
                {
                    stainResult = "Pending";
                }
                else if (stainResult.ToUpper() == "SEE COMMENT")
                {
                    stainResult = stainResultItem.ReportComment;
                }
                else
                {
                    string specialStainReportComment = stainResultItem.ReportComment;

                    if (!string.IsNullOrEmpty(specialStainReportComment))
                    {
                        stainResult += " - " + specialStainReportComment;
                    }
                }

                rowSpecialStainClone.SelectSingleNode("descendant::w:r[w:t='stain_description']/w:t", this.m_NameSpaceManager).InnerText = stainDescription;
                rowSpecialStainClone.SelectSingleNode("descendant::w:r[w:t='stain_result']/w:t", this.m_NameSpaceManager).InnerText = stainResult;

                string block = surgicalSpecimen.GetBlockFromTestOrderId(stainResultItem.TestOrderId);
                rowSpecialStainClone.SelectSingleNode("descendant::w:r[w:t='block_description']/w:t", this.m_NameSpaceManager).InnerText = block;

                tableNodeSS.InsertAfter(rowSpecialStainClone, insertAfterRowSS);
                insertAfterRowSS = rowSpecialStainClone;
            }

            return insertAfterRowSS;
        }