Beispiel #1
0
        public void PrintLabels(Business.Test.AccessionOrder accessionOrder, Business.Test.AliquotOrder aliquotOrder)
        {
            Business.Test.Model.Test kappa  = YellowstonePathology.Business.Test.Model.TestCollectionInstance.GetClone("360"); // KappaByISH();
            Business.Test.Model.Test lambda = YellowstonePathology.Business.Test.Model.TestCollectionInstance.GetClone("361"); // LambdaByISH();
            Business.Test.Model.Test u6     = YellowstonePathology.Business.Test.Model.TestCollectionInstance.GetClone("383"); // U6();

            //add test order that need to be ordered automatically
            if (accessionOrder.PanelSetOrderCollection.DoesStainOrderExist(kappa.TestId) == true && accessionOrder.PanelSetOrderCollection.DoesStainOrderExist(lambda.TestId) == true)
            {
                if (accessionOrder.PanelSetOrderCollection.DoesStainOrderExist(u6.TestId) == false)
                {
                    Business.Test.PanelSetOrder panelSetOrder = accessionOrder.PanelSetOrderCollection.GetPanelSetOrderByTestId(kappa.TestId);
                    YellowstonePathology.Business.Visitor.OrderTestVisitor orderTestVisitor = new Business.Visitor.OrderTestVisitor(panelSetOrder.ReportNo, u6, null, null, false, aliquotOrder, false, false, accessionOrder.TaskOrderCollection);
                    accessionOrder.TakeATrip(orderTestVisitor);
                    this.Add(new TestOrderPanelSetOrderView(panelSetOrder, orderTestVisitor.TestOrder));
                }
            }

            //add slides and print.
            foreach (TestOrderPanelSetOrderView item in this)
            {
                Business.Test.Model.TestOrder testOrder = accessionOrder.PanelSetOrderCollection.GetTestOrderByTestOrderId(item.TestOrderId);
                if (testOrder.SlideOrderCollection.Count == 0)
                {
                    YellowstonePathology.Business.Visitor.AddSlideOrderVisitor addSlideOrderVisitor = new Business.Visitor.AddSlideOrderVisitor(aliquotOrder, testOrder);
                    accessionOrder.TakeATrip(addSlideOrderVisitor);

                    Business.HL7View.VentanaStainOrder ventanaStainOrder = new Business.HL7View.VentanaStainOrder();
                    ventanaStainOrder.HandleOrder(accessionOrder, addSlideOrderVisitor.NewSlideOrder);
                }
            }
        }
Beispiel #2
0
        private void ButtonAddUnstainedSlide_Click(object sender, RoutedEventArgs e)
        {
            YellowstonePathology.Business.Test.Model.UnstainedSlide unstainedSlide = new Business.Test.Model.UnstainedSlide();
            Business.Visitor.OrderTestVisitor orderTestVisitor = new Business.Visitor.OrderTestVisitor(this.m_PanelSetOrder.ReportNo, unstainedSlide, null, null, false, this.m_AliquotOrder, true, false, this.m_AccessionOrder.TaskOrderCollection);
            orderTestVisitor.Visit(this.m_PanelSetOrder);

            Business.Visitor.AddSlideOrderVisitor addSlideOrderVisitor = new Business.Visitor.AddSlideOrderVisitor(this.m_AliquotOrder, orderTestVisitor.TestOrder);
            addSlideOrderVisitor.Visit(this.m_AccessionOrder);
            addSlideOrderVisitor.NewSlideOrder.LabelType = "DirectPrint";
            this.NotifyPropertyChanged(string.Empty);
        }
        private void ButtonAddSlideOrder_Click(object sender, RoutedEventArgs e)
        {
            YellowstonePathology.Business.Test.Model.TestOrderCollection testOrderCollection = this.m_AliquotAndStainOrderView.GetSelectedTestOrders();
            foreach (YellowstonePathology.Business.Test.Model.TestOrder testOrder in testOrderCollection)
            {
                YellowstonePathology.Business.Test.AliquotOrder            aliquotOrder         = this.m_AccessionOrder.SpecimenOrderCollection.GetAliquotOrder(testOrder.AliquotOrder.AliquotOrderId);
                YellowstonePathology.Business.Visitor.AddSlideOrderVisitor addSlideOrderVisitor = new Business.Visitor.AddSlideOrderVisitor(aliquotOrder, testOrder);
                this.m_AccessionOrder.TakeATrip(addSlideOrderVisitor);
            }

            this.m_AliquotAndStainOrderView = new AliquotAndStainOrderView(this.m_AccessionOrder, this.m_PanelSetOrder);
            this.NotifyPropertyChanged("AliquotAndStainOrderView");
        }
Beispiel #4
0
        private void AddAliquot()
        {
            YellowstonePathology.Business.Test.Model.HandE handeTest = new Business.Test.Model.HandE();
            this.m_ClientOrderReceivingHandler.AccessionOrder.PrintMateColumnNumber = 1;
            string reportNo = this.m_ClientOrderReceivingHandler.AccessionOrder.PanelSetOrderCollection.GetSurgical().ReportNo;
            foreach (YellowstonePathology.Business.Specimen.Model.SpecimenOrder specimenOrder in this.m_ClientOrderReceivingHandler.AccessionOrder.SpecimenOrderCollection)
            {
                YellowstonePathology.Business.Test.AliquotOrder aliquotOrder = specimenOrder.AliquotOrderCollection.AddBlock(specimenOrder, "Direct Print", this.m_ClientOrderReceivingHandler.AccessionOrder.AccessionDate.Value);
                specimenOrder.AliquotRequestCount = specimenOrder.AliquotOrderCollection.Count;
                YellowstonePathology.Business.Visitor.OrderTestVisitor orderTestVisitor = new Business.Visitor.OrderTestVisitor(reportNo, handeTest, null, null, false, aliquotOrder, false, false, this.m_ClientOrderReceivingHandler.AccessionOrder.TaskOrderCollection);
                this.m_ClientOrderReceivingHandler.AccessionOrder.TakeATrip(orderTestVisitor);

                YellowstonePathology.Business.Visitor.AddSlideOrderVisitor addSlideOrderVisitor = new Business.Visitor.AddSlideOrderVisitor(aliquotOrder, orderTestVisitor.TestOrder);
                this.m_ClientOrderReceivingHandler.AccessionOrder.TakeATrip(addSlideOrderVisitor);
            }
        }
Beispiel #5
0
        private void ButtonAddSlide_Click(object sender, RoutedEventArgs e)
        {
            Business.Test.Model.Test kappa  = YellowstonePathology.Business.Test.Model.TestCollectionInstance.GetClone("360"); // KappaByISH();
            Business.Test.Model.Test lambda = YellowstonePathology.Business.Test.Model.TestCollectionInstance.GetClone("361"); // LambdaByISH();
            Business.Test.Model.Test u6     = YellowstonePathology.Business.Test.Model.TestCollectionInstance.GetClone("383"); // U6();

            //add test order that need to be ordered automatically
            if (this.m_AccessionOrder.PanelSetOrderCollection.DoesStainOrderExist(kappa.TestId) == true && this.m_AccessionOrder.PanelSetOrderCollection.DoesStainOrderExist(lambda.TestId) == true)
            {
                if (this.m_AccessionOrder.PanelSetOrderCollection.DoesStainOrderExist(u6.TestId) == false)
                {
                    Business.Test.PanelSetOrder panelSetOrder = this.m_AccessionOrder.PanelSetOrderCollection.GetPanelSetOrderByTestId(kappa.TestId);
                    YellowstonePathology.Business.Visitor.OrderTestVisitor orderTestVisitor = new Business.Visitor.OrderTestVisitor(panelSetOrder.ReportNo, u6, null, null, false, this.m_AliquotOrder, false, false, this.m_AccessionOrder.TaskOrderCollection);
                    this.m_AccessionOrder.TakeATrip(orderTestVisitor);
                }
            }

            YellowstonePathology.Business.Visitor.AddSlideOrderVisitor addSlideOrderVisitor = new Business.Visitor.AddSlideOrderVisitor(this.m_AliquotOrder, this.m_TestOrder);
            this.m_AccessionOrder.TakeATrip(addSlideOrderVisitor);
        }
Beispiel #6
0
        private void AddBlocksToSpecimen(YellowstonePathology.Business.Test.Model.Test test, int quantity, string blockType, string prefix)
        {
            string patientInitials = YellowstonePathology.Business.Helper.PatientHelper.GetPatientInitials(this.m_AccessionOrder.PFirstName, this.m_AccessionOrder.PLastName);

            for (int i = 0; i < quantity; i++)
            {
                YellowstonePathology.Business.Test.AliquotOrder  aliquotOrder  = this.m_SpecimenOrder.AliquotOrderCollection.AddBlock(this.m_SpecimenOrder, YellowstonePathology.Business.Specimen.Model.AliquotLabelType.DirectPrint, this.m_AccessionOrder.AccessionDate.Value);
                YellowstonePathology.Business.Test.PanelSetOrder panelSetOrder = this.m_AccessionOrder.PanelSetOrderCollection.GetSurgical();
                if (panelSetOrder == null)
                {
                    panelSetOrder = this.m_AccessionOrder.PanelSetOrderCollection.GetPanelSetOrder(this.m_ReportNoToUse);
                }

                YellowstonePathology.Business.Visitor.OrderTestVisitor orderTestVisitor = new Business.Visitor.OrderTestVisitor(panelSetOrder.ReportNo, test, test.OrderComment, null, false, aliquotOrder, false, false, this.m_AccessionOrder.TaskOrderCollection);
                this.m_AccessionOrder.TakeATrip(orderTestVisitor);

                YellowstonePathology.Business.Visitor.AddSlideOrderVisitor addSlideOrderVisitor = new Business.Visitor.AddSlideOrderVisitor(aliquotOrder, orderTestVisitor.TestOrder);
                this.m_AccessionOrder.TakeATrip(addSlideOrderVisitor);
            }
        }
        private void OrderTestOnSelectedAliquots(YellowstonePathology.Business.Test.Model.Test test, bool orderedAsDual)
        {
            YellowstonePathology.Business.Test.AliquotOrderCollection selectedAliquots = this.m_AliquotAndStainOrderView.GetSelectedAliquots();
            foreach (YellowstonePathology.Business.Test.AliquotOrder aliquotOrder in selectedAliquots)
            {
                YellowstonePathology.Business.Visitor.OrderTestVisitor orderTestVisitor = new Business.Visitor.OrderTestVisitor(this.m_PanelSetOrder.ReportNo, test, test.OrderComment, null, orderedAsDual, aliquotOrder, false, false, this.m_AccessionOrder.TaskOrderCollection);
                this.m_AccessionOrder.TakeATrip(orderTestVisitor);

                if ((aliquotOrder.AliquotType == "Block" ||
                     aliquotOrder.AliquotType == "FrozenBlock" ||
                     aliquotOrder.AliquotType == "CellBlock"))
                {
                    YellowstonePathology.Business.Visitor.AddSlideOrderVisitor addSlideOrderVisitor = new Business.Visitor.AddSlideOrderVisitor(aliquotOrder, orderTestVisitor.TestOrder);
                    this.m_AccessionOrder.TakeATrip(addSlideOrderVisitor);
                }

                if (test.NeedsAcknowledgement == true)
                {
                    this.m_StainAcknowledgementTaskOrderVisitor.AddTestOrder(orderTestVisitor.TestOrder);
                }
            }
        }
        private void AddBlocksToSpecimen(YellowstonePathology.Business.Test.Model.Test test, int quantity, string blockType, string prefix)
        {
            string patientInitials = YellowstonePathology.Business.Helper.PatientHelper.GetPatientInitials(this.m_AccessionOrder.PFirstName, this.m_AccessionOrder.PLastName);

            for (int i = 0; i < quantity; i++)
            {
                YellowstonePathology.Business.Test.AliquotOrder aliquotOrder = this.m_SpecimenOrder.AliquotOrderCollection.AddBlock(this.m_SpecimenOrder, YellowstonePathology.Business.Specimen.Model.AliquotLabelType.DirectPrint, this.m_AccessionOrder.AccessionDate.Value);
                YellowstonePathology.Business.Test.PanelSetOrder panelSetOrder = this.m_AccessionOrder.PanelSetOrderCollection.GetSurgical();
                if (panelSetOrder == null) panelSetOrder = this.m_AccessionOrder.PanelSetOrderCollection.GetPanelSetOrder(this.m_ReportNoToUse);

                YellowstonePathology.Business.Visitor.OrderTestVisitor orderTestVisitor = new Business.Visitor.OrderTestVisitor(panelSetOrder.ReportNo, test, test.OrderComment, null, false, aliquotOrder, false, false, this.m_AccessionOrder.TaskOrderCollection);
                this.m_AccessionOrder.TakeATrip(orderTestVisitor);

                YellowstonePathology.Business.Visitor.AddSlideOrderVisitor addSlideOrderVisitor = new Business.Visitor.AddSlideOrderVisitor(aliquotOrder, orderTestVisitor.TestOrder);
                this.m_AccessionOrder.TakeATrip(addSlideOrderVisitor);
            }
        }
 private void ButtonAddSlide_Click(object sender, RoutedEventArgs e)
 {
     YellowstonePathology.Business.Visitor.AddSlideOrderVisitor addSlideOrderVisitor = new Business.Visitor.AddSlideOrderVisitor(this.m_AliquotOrder, this.m_TestOrder);
     this.m_AccessionOrder.TakeATrip(addSlideOrderVisitor);
 }
        private void OrderTestOnSelectedAliquots(YellowstonePathology.Business.Test.Model.Test test, bool orderedAsDual)
        {
            YellowstonePathology.Business.Test.AliquotOrderCollection selectedAliquots = this.m_AliquotAndStainOrderView.GetSelectedAliquots();
            foreach(YellowstonePathology.Business.Test.AliquotOrder aliquotOrder in selectedAliquots)
            {
                YellowstonePathology.Business.Visitor.OrderTestVisitor orderTestVisitor = new Business.Visitor.OrderTestVisitor(this.m_PanelSetOrder.ReportNo, test, test.OrderComment, null, orderedAsDual, aliquotOrder, false, false, this.m_AccessionOrder.TaskOrderCollection);
                this.m_AccessionOrder.TakeATrip(orderTestVisitor);

                if ((aliquotOrder.AliquotType == "Block" ||
                    aliquotOrder.AliquotType == "FrozenBlock" ||
                    aliquotOrder.AliquotType == "CellBlock"))
                {
                    YellowstonePathology.Business.Visitor.AddSlideOrderVisitor addSlideOrderVisitor = new Business.Visitor.AddSlideOrderVisitor(aliquotOrder, orderTestVisitor.TestOrder);
                    this.m_AccessionOrder.TakeATrip(addSlideOrderVisitor);
                }

                if (test.NeedsAcknowledgement == true)
                {
                    this.m_StainAcknowledgementTaskOrderVisitor.AddTestOrder(orderTestVisitor.TestOrder);
                }
            }
        }
        private void OrderAliquotsAndTestOnSelectedSpecimen(YellowstonePathology.Business.Test.Model.Test test, bool orderedAsDual)
        {
            YellowstonePathology.Business.Specimen.Model.SpecimenOrderCollection selectedSpecimen = this.m_AliquotAndStainOrderView.GetSelectedSpecimen();
            foreach (YellowstonePathology.Business.Specimen.Model.SpecimenOrder specimenOrder in selectedSpecimen)
            {
                for (int i = 0; i < this.m_Aliquots.Value; i++)
                {
                    YellowstonePathology.Business.Test.AliquotOrder aliquotOrder = null;

                    switch (this.m_Aliquot.AliquotType)
                    {
                        case "Block":
                            aliquotOrder = specimenOrder.AliquotOrderCollection.AddBlock(specimenOrder, this.m_Aliquot.IdentificationType, this.m_AccessionOrder.AccessionDate.Value);
                            break;
                        case "FrozenBlock":
                            aliquotOrder = specimenOrder.AliquotOrderCollection.AddFrozenBlock(specimenOrder, this.m_Aliquot.IdentificationType, this.m_AccessionOrder.AccessionDate.Value);
                            break;
                        case "CellBlock":
                            aliquotOrder = specimenOrder.AliquotOrderCollection.AddCellBlock(specimenOrder, this.m_Aliquot.IdentificationType, this.m_AccessionOrder.AccessionDate.Value);
                            break;
                        case "Slide":
                            aliquotOrder = specimenOrder.AliquotOrderCollection.AddSlide(specimenOrder, this.m_Aliquot.IdentificationType, this.m_AccessionOrder.AccessionDate.Value);
                            break;
                        case "Specimen":
                            aliquotOrder = specimenOrder.AliquotOrderCollection.AddSpecimen(specimenOrder, this.m_Aliquot.IdentificationType, this.m_AccessionOrder.AccessionDate.Value);
                            break;
                    }

                    specimenOrder.AliquotRequestCount = specimenOrder.AliquotOrderCollection.Count;
                    if (this.Test != null)
                    {
                        YellowstonePathology.Business.Visitor.OrderTestVisitor orderTestVisitor = new Business.Visitor.OrderTestVisitor(this.m_PanelSetOrder.ReportNo, test, test.OrderComment, null, false, aliquotOrder, false, false, this.m_AccessionOrder.TaskOrderCollection);
                        this.m_AccessionOrder.TakeATrip(orderTestVisitor);

                        if ((aliquotOrder.AliquotType == "Block" ||
                            aliquotOrder.AliquotType == "FrozenBlock" ||
                            aliquotOrder.AliquotType == "CellBlock"))
                        {
                            YellowstonePathology.Business.Visitor.AddSlideOrderVisitor addSlideOrderVisitor = new Business.Visitor.AddSlideOrderVisitor(aliquotOrder, orderTestVisitor.TestOrder);
                            this.m_AccessionOrder.TakeATrip(addSlideOrderVisitor);
                        }

                        if (test.NeedsAcknowledgement == true)
                        {
                            this.m_StainAcknowledgementTaskOrderVisitor.AddTestOrder(orderTestVisitor.TestOrder);
                        }

                        this.m_AliquotAndStainOrderView = new AliquotAndStainOrderView(this.m_AccessionOrder, this.m_PanelSetOrder);
                    }
                }
            }

            //this.Save(false);
        }
        private void ButtonAddSlideOrder_Click(object sender, RoutedEventArgs e)
        {
            YellowstonePathology.Business.Test.Model.TestOrderCollection testOrderCollection = this.m_AliquotAndStainOrderView.GetSelectedTestOrders();
            foreach (YellowstonePathology.Business.Test.Model.TestOrder testOrder in testOrderCollection)
            {
                YellowstonePathology.Business.Test.AliquotOrder aliquotOrder = this.m_AccessionOrder.SpecimenOrderCollection.GetAliquotOrder(testOrder.AliquotOrder.AliquotOrderId);
                YellowstonePathology.Business.Visitor.AddSlideOrderVisitor addSlideOrderVisitor = new Business.Visitor.AddSlideOrderVisitor(aliquotOrder, testOrder);
                this.m_AccessionOrder.TakeATrip(addSlideOrderVisitor);
            }

            this.m_AliquotAndStainOrderView = new AliquotAndStainOrderView(this.m_AccessionOrder, this.m_PanelSetOrder);
            this.NotifyPropertyChanged("AliquotAndStainOrderView");
        }
        private void OrderAliquotsAndTestOnSelectedSpecimen(YellowstonePathology.Business.Test.Model.Test test, bool orderedAsDual)
        {
            YellowstonePathology.Business.Specimen.Model.SpecimenOrderCollection selectedSpecimen = this.m_AliquotAndStainOrderView.GetSelectedSpecimen();
            foreach (YellowstonePathology.Business.Specimen.Model.SpecimenOrder specimenOrder in selectedSpecimen)
            {
                for (int i = 0; i < this.m_Aliquots.Value; i++)
                {
                    YellowstonePathology.Business.Test.AliquotOrder aliquotOrder = null;

                    switch (this.m_Aliquot.AliquotType)
                    {
                    case "Block":
                        aliquotOrder = specimenOrder.AliquotOrderCollection.AddBlock(specimenOrder, this.m_Aliquot.IdentificationType, this.m_AccessionOrder.AccessionDate.Value);
                        break;

                    case "FrozenBlock":
                        aliquotOrder = specimenOrder.AliquotOrderCollection.AddFrozenBlock(specimenOrder, this.m_Aliquot.IdentificationType, this.m_AccessionOrder.AccessionDate.Value);
                        break;

                    case "CellBlock":
                        aliquotOrder = specimenOrder.AliquotOrderCollection.AddCellBlock(specimenOrder, this.m_Aliquot.IdentificationType, this.m_AccessionOrder.AccessionDate.Value);
                        break;

                    case "Slide":
                        aliquotOrder = specimenOrder.AliquotOrderCollection.AddSlide(specimenOrder, this.m_Aliquot.IdentificationType, this.m_AccessionOrder.AccessionDate.Value);
                        break;

                    case "Specimen":
                        aliquotOrder = specimenOrder.AliquotOrderCollection.AddSpecimen(specimenOrder, this.m_Aliquot.IdentificationType, this.m_AccessionOrder.AccessionDate.Value);
                        break;
                    }

                    specimenOrder.AliquotRequestCount = specimenOrder.AliquotOrderCollection.Count;
                    if (this.Test != null)
                    {
                        YellowstonePathology.Business.Visitor.OrderTestVisitor orderTestVisitor = new Business.Visitor.OrderTestVisitor(this.m_PanelSetOrder.ReportNo, test, test.OrderComment, null, false, aliquotOrder, false, false, this.m_AccessionOrder.TaskOrderCollection);
                        this.m_AccessionOrder.TakeATrip(orderTestVisitor);

                        if ((aliquotOrder.AliquotType == "Block" ||
                             aliquotOrder.AliquotType == "FrozenBlock" ||
                             aliquotOrder.AliquotType == "CellBlock"))
                        {
                            YellowstonePathology.Business.Visitor.AddSlideOrderVisitor addSlideOrderVisitor = new Business.Visitor.AddSlideOrderVisitor(aliquotOrder, orderTestVisitor.TestOrder);
                            this.m_AccessionOrder.TakeATrip(addSlideOrderVisitor);
                        }

                        if (test.NeedsAcknowledgement == true)
                        {
                            this.m_StainAcknowledgementTaskOrderVisitor.AddTestOrder(orderTestVisitor.TestOrder);
                        }

                        this.m_AliquotAndStainOrderView = new AliquotAndStainOrderView(this.m_AccessionOrder, this.m_PanelSetOrder);
                    }
                }
            }

            //this.Save(false);
        }
Beispiel #14
0
 private void ButtonAddHandSlide_Click(object sender, RoutedEventArgs e)
 {
     this.m_TestOrder.PerformedByHand = true;
     YellowstonePathology.Business.Visitor.AddSlideOrderVisitor addSlideOrderVisitor = new Business.Visitor.AddSlideOrderVisitor(this.m_AliquotOrder, this.m_TestOrder);
     this.m_AccessionOrder.TakeATrip(addSlideOrderVisitor);
 }