Ejemplo n.º 1
0
        public void StartWomensHealthProfilePath()
        {
            if (this.m_AccessionOrder.PanelSetOrderCollection.HasWomensHealthProfileOrder() == true)
            {
                YellowstonePathology.Business.Domain.Physician physician = YellowstonePathology.Business.Gateway.PhysicianClientGateway.GetPhysicianByPhysicianId(this.m_AccessionOrder.PhysicianId);

                YellowstonePathology.Business.Audit.Model.IsWHPAllDoneAuditCollection isWHPAllDoneAuditCollection = new Business.Audit.Model.IsWHPAllDoneAuditCollection(this.m_AccessionOrder);
                isWHPAllDoneAuditCollection.Run();

                if (isWHPAllDoneAuditCollection.ActionRequired == true)
                {
                    YellowstonePathology.Business.ClientOrder.Model.ClientOrder           clientOrder  = null;
                    YellowstonePathology.Business.ClientOrder.Model.ClientOrderCollection clientOrders = YellowstonePathology.Business.Gateway.ClientOrderGateway.GetClientOrdersByMasterAccessionNo(this.m_AccessionOrder.MasterAccessionNo);

                    if (clientOrders.Count > 0)
                    {
                        clientOrder = clientOrders[0];
                    }

                    this.m_PageNavigationWindow = new PageNavigationWindow(this.m_SystemIdentity);
                    YellowstonePathology.UI.Login.WomensHealthProfilePath womensHealthProfilePath = new YellowstonePathology.UI.Login.WomensHealthProfilePath(this.m_AccessionOrder, clientOrder, this.m_PageNavigationWindow.PageNavigator, m_PageNavigationWindow, Visibility.Collapsed);
                    womensHealthProfilePath.Back   += new Login.WomensHealthProfilePath.BackEventHandler(WomensHealthProfilePath_Finished);
                    womensHealthProfilePath.Finish += new Login.WomensHealthProfilePath.FinishEventHandler(WomensHealthProfilePath_Finished);
                    womensHealthProfilePath.Start();
                    this.m_PageNavigationWindow.ShowDialog();
                }
            }
        }
Ejemplo n.º 2
0
        public MTDohResultView(string reportNo, YellowstonePathology.Business.Test.AccessionOrder accessionOrder)
        {
            this.m_AccessionOrder = accessionOrder;
            this.m_PanelSetOrder = this.m_AccessionOrder.PanelSetOrderCollection.GetPanelSetOrder(reportNo);

            this.m_OrderingPhysician = YellowstonePathology.Business.Gateway.PhysicianClientGateway.GetPhysicianByPhysicianId(this.m_AccessionOrder.PhysicianId);
        }
Ejemplo n.º 3
0
        public AdditionalTestingEMailPage(YellowstonePathology.Business.Test.PanelSetOrder panelSetOrder,
                                          YellowstonePathology.Business.Test.AccessionOrder accessionOrder)
        {
            this.m_PanelSetOrder  = panelSetOrder;
            this.m_AccessionOrder = accessionOrder;

            if (string.IsNullOrEmpty(this.m_PanelSetOrder.AdditionalTestingEmailAddress) == true)
            {
                YellowstonePathology.Business.Domain.Physician physician = YellowstonePathology.Business.Gateway.PhysicianClientGateway.GetPhysicianByPhysicianId(this.m_AccessionOrder.PhysicianId);
                this.m_PanelSetOrder.AdditionalTestingEmailAddress = physician.PublishNotificationEmailAddress;
            }

            if (string.IsNullOrEmpty(this.m_PanelSetOrder.AdditionalTestingEmailMessage) == true)
            {
                this.m_PanelSetOrder.AdditionalTestingEmailMessage = "Additional Testing is being performed.  Use YPI Connect to see details." + Environment.NewLine +
                                                                     Environment.NewLine + Environment.NewLine + "If you don't have access to YPI Connect please call us at (406)238-6360.";
            }

            InitializeComponent();

            DataContext = this;

            Loaded   += AdditionalTestingEMailPage_Loaded;
            Unloaded += AdditionalTestingEMailPage_Unloaded;
        }
Ejemplo n.º 4
0
        public static View.ClientPhysicianView GetClientPhysicianViewByClientId(int clientId)
        {
            YellowstonePathology.Business.View.ClientPhysicianView result = new YellowstonePathology.Business.View.ClientPhysicianView();
            YellowstonePathology.Business.Mongo.Server             server = new Business.Mongo.TestServer(YellowstonePathology.Business.Mongo.MongoTestServer.LISDatabaseName);
            MongoCollection clientCollection   = server.Database.GetCollection <BsonDocument>("Client");
            BsonDocument    clientBsonDocument = clientCollection.FindOneAs <BsonDocument>(Query.EQ("ClientId", BsonValue.Create(clientId)));

            YellowstonePathology.Business.Mongo.BSONPropertyWriter.Write(clientBsonDocument, result);

            MongoCollection  physicianClientCollection = server.Database.GetCollection <BsonDocument>("PhysicianClient");
            MongoCursor      physicianClientCursor     = physicianClientCollection.FindAs <BsonDocument>(Query.EQ("ClientId", BsonValue.Create(clientId)));
            List <BsonValue> physicianIdList           = new List <BsonValue>();

            foreach (BsonDocument bsonDocument in physicianClientCursor)
            {
                physicianIdList.Add(bsonDocument.GetValue("PhysicianId"));
            }

            MongoCollection physicianCollection = server.Database.GetCollection <BsonDocument>("Physician");
            MongoCursor     physicianCursor     = physicianCollection.FindAs <BsonDocument>(Query.In("PhysicianId", physicianIdList)).SetSortOrder(SortBy.Ascending("FirstName"));

            foreach (BsonDocument bsonDocument in physicianCursor)
            {
                YellowstonePathology.Business.Domain.Physician physician = new YellowstonePathology.Business.Domain.Physician();
                YellowstonePathology.Business.Mongo.BSONPropertyWriter.Write(bsonDocument, physician);
                result.Physicians.Add(physician);
            }

            return(result);
        }
Ejemplo n.º 5
0
        private YellowstonePathology.Business.Rules.MethodResult DoTypingFinalChecks()
        {
            YellowstonePathology.Business.Rules.MethodResult methodResult = new Business.Rules.MethodResult();
            methodResult.Success = true;

            if (this.m_TypingUI.AccessionOrder.ClientId == 558)
            {
                string message = string.Empty;
                if (string.IsNullOrEmpty(this.m_TypingUI.AccessionOrder.SvhAccount) == true)
                {
                    message += "The SVH Account is blank.";
                    methodResult.Success = false;
                }
                if (string.IsNullOrEmpty(this.m_TypingUI.AccessionOrder.SvhMedicalRecord) == true)
                {
                    message += "The SVH MRN is blank.";
                    methodResult.Success = false;
                }
                methodResult.Message = message;
            }

            YellowstonePathology.Business.Domain.Physician physician = YellowstonePathology.Business.Gateway.PhysicianClientGateway.GetPhysicianByPhysicianId(this.m_TypingUI.AccessionOrder.PhysicianId);
            if (string.IsNullOrEmpty(physician.Npi) == true)
            {
                methodResult.Message += "The provider NPI is blank.";
                methodResult.Success  = false;
            }

            if (this.m_TypingUI.SurgicalTestOrder.AssignedToId == 0)
            {
                methodResult.Success = false;
                methodResult.Message = "Please assign a pathologist to this case.";
            }
            return(methodResult);
        }
Ejemplo n.º 6
0
        public static Domain.PhysicianCollection GetPhysiciansByName(string firstName, string lastName)
        {
            YellowstonePathology.Business.Domain.PhysicianCollection result = new YellowstonePathology.Business.Domain.PhysicianCollection();
            YellowstonePathology.Business.Mongo.Server server = new Business.Mongo.TestServer(YellowstonePathology.Business.Mongo.MongoTestServer.LISDatabaseName);
            MongoCollection collection = server.Database.GetCollection <BsonDocument>("Physician");
            MongoCursor     cursor     = null;

            if (string.IsNullOrEmpty(firstName) == false)
            {
                cursor = collection.FindAs <BsonDocument>(Query.And(Query.Matches("LastName", BsonRegularExpression.Create("^" + lastName + ".*", "i")),
                                                                    Query.Matches("FirstName", BsonRegularExpression.Create("^" + firstName + ".*", "i")))).SetSortOrder(SortBy.Ascending("LastName", "FirstName"));
            }
            else
            {
                cursor = collection.FindAs <BsonDocument>(Query.Matches("LastName", BsonRegularExpression.Create("^" + lastName + ".*", "i"))).SetSortOrder(SortBy.Ascending("LastName", "FirstName"));
            }

            foreach (BsonDocument bsonDocument in cursor)
            {
                YellowstonePathology.Business.Domain.Physician physician = new YellowstonePathology.Business.Domain.Physician();
                YellowstonePathology.Business.Mongo.BSONPropertyWriter.Write(bsonDocument, physician);
                result.Add(physician);
            }

            return(result);
        }
Ejemplo n.º 7
0
        public StandingOrderPage(YellowstonePathology.Business.Test.AccessionOrder accessionOrder)
        {
            this.m_AccessionOrder = accessionOrder;

            this.m_WomensHealthProfileTest = new YellowstonePathology.Business.Test.WomensHealthProfile.WomensHealthProfileTest();
            this.m_Physician = YellowstonePathology.Business.Gateway.PhysicianClientGateway.GetPhysicianByPhysicianId(this.m_AccessionOrder.PhysicianId);
            this.m_StandingOrderCollection = this.m_Physician.GetStandingOrderCollection();

            this.m_HPVStandingOrderCollection     = YellowstonePathology.Business.Client.Model.StandingOrderCollection.GetHPVStandingOrders();
            this.m_HPV1618StandingOrderCollection = YellowstonePathology.Business.Client.Model.StandingOrderCollection.GetHPV1618StandingOrders();

            if (accessionOrder.PanelSetOrderCollection.Exists(this.m_WomensHealthProfileTest.PanelSetId) == true)
            {
                this.m_WomensHealthProfileTestOrder  = (YellowstonePathology.Business.Test.WomensHealthProfile.WomensHealthProfileTestOrder)accessionOrder.PanelSetOrderCollection.GetPanelSetOrder(this.m_WomensHealthProfileTest.PanelSetId);
                this.m_WomensHealthProfileVisibility = System.Windows.Visibility.Visible;
                this.UpdateWomensHealthProfile();
            }
            else
            {
                this.m_WomensHealthProfileVisibility = System.Windows.Visibility.Collapsed;
            }

            this.m_AccessionOrderList = new List <Business.Test.AccessionOrder>();
            this.m_AccessionOrderList.Add(this.m_AccessionOrder);

            InitializeComponent();

            DataContext = this;
        }
Ejemplo n.º 8
0
        private void HandleNotificationEmail(YellowstonePathology.Business.Test.PanelSetOrder panelSetOrder)
        {
            YellowstonePathology.Business.Domain.Physician physician = YellowstonePathology.Business.Gateway.PhysicianClientGateway.GetPhysicianByMasterAccessionNo(panelSetOrder.MasterAccessionNo);
            if (physician.SendPublishNotifications == true)
            {
                if (panelSetOrder.Distribute == true)
                {
                    string subject = "You have a result ready for review: " + panelSetOrder.PanelSetName;
                    string body    = "You have a patient report ready. You can review the report by using YPI Connect.  If you don't have access to YPI Connect please call us at (406)238-6360.";

                    System.Net.Mail.MailAddress from = new System.Net.Mail.MailAddress("*****@*****.**");
                    System.Net.Mail.MailAddress to   = new System.Net.Mail.MailAddress(physician.PublishNotificationEmailAddress);
                    System.Net.Mail.MailAddress bcc  = new System.Net.Mail.MailAddress("*****@*****.**");

                    System.Net.Mail.MailMessage message = new System.Net.Mail.MailMessage(from, to);
                    message.Subject = subject;
                    message.Body    = body;
                    message.Bcc.Add(bcc);

                    System.Net.Mail.SmtpClient client = new System.Net.Mail.SmtpClient("10.1.2.111");

                    Uri uri = new Uri("http://tempuri.org/");
                    System.Net.ICredentials      credentials = System.Net.CredentialCache.DefaultCredentials;
                    System.Net.NetworkCredential credential  = credentials.GetCredential(uri, "Basic");

                    client.Credentials = credential;
                    client.Send(message);

                    panelSetOrder.TimeOfLastPublishNotification = DateTime.Now;
                    panelSetOrder.PublishNotificationSent       = true;
                }
            }
        }
Ejemplo n.º 9
0
        public void ToXml(XElement document)
        {
            YellowstonePathology.Business.Domain.Physician casePhysician = YellowstonePathology.Business.Gateway.PhysicianClientGateway.GetPhysicianByPhysicianId(this.m_AccessionOrder.PhysicianId);
            YellowstonePathology.Business.OrderIdParser    orderIdParser = new YellowstonePathology.Business.OrderIdParser(this.m_AccessionOrder.PanelSetOrderCollection[0].ReportNo);

            MSH msh = new ARUPMSH();

            msh.ToXml(document);

            PID pid = new PID(this.m_AccessionOrder);

            pid.ToXml(document);

            PV1 pv1 = new PV1(this.m_AccessionOrder, casePhysician);

            pv1.ToXml(document);

            IN1 in1 = new IN1(this.m_AccessionOrder);

            in1.ToXml(document);

            ORC orc = new ORC(this.m_AccessionOrder.PanelSetOrderCollection[0].ReportNo, this.m_AccessionOrder, casePhysician);

            orc.ToXml(document);

            string serverFileName = YellowstonePathology.Document.CaseDocumentPath.GetPath(orderIdParser) + "\\" + this.m_AccessionOrder.PanelSetOrderCollection[0].ReportNo + ".HL7.xml";
            string mirthFileName  = @"\\YPIIInterface1\ChannelData\Outgoing\Testing\" + this.m_AccessionOrder.PanelSetOrderCollection[0].ReportNo + ".HL7.xml";

            using (System.IO.StreamWriter sw = new System.IO.StreamWriter(serverFileName))
            {
                document.Save(sw);
            }

            System.IO.File.Copy(serverFileName, mirthFileName);
        }
Ejemplo n.º 10
0
        public MTDohResultView(string reportNo, YellowstonePathology.Business.Test.AccessionOrder accessionOrder)
        {
            this.m_AccessionOrder = accessionOrder;
            this.m_PanelSetOrder  = this.m_AccessionOrder.PanelSetOrderCollection.GetPanelSetOrder(reportNo);

            this.m_OrderingPhysician = YellowstonePathology.Business.Gateway.PhysicianClientGateway.GetPhysicianByPhysicianId(this.m_AccessionOrder.PhysicianId);
        }
Ejemplo n.º 11
0
        public StandingOrderPage(YellowstonePathology.Business.Test.AccessionOrder accessionOrder)
        {
            this.m_AccessionOrder = accessionOrder;

            this.m_WomensHealthProfileTest = new YellowstonePathology.Business.Test.WomensHealthProfile.WomensHealthProfileTest();
            this.m_Physician = YellowstonePathology.Business.Gateway.PhysicianClientGateway.GetPhysicianByPhysicianId(this.m_AccessionOrder.PhysicianId);
            this.m_StandingOrderCollection = this.m_Physician.GetStandingOrderCollection();

            this.m_HPVStandingOrderCollection = YellowstonePathology.Business.Client.Model.StandingOrderCollection.GetHPVStandingOrders();
            this.m_HPV1618StandingOrderCollection = YellowstonePathology.Business.Client.Model.StandingOrderCollection.GetHPV1618StandingOrders();

            if (accessionOrder.PanelSetOrderCollection.Exists(this.m_WomensHealthProfileTest.PanelSetId) == true)
            {
                this.m_WomensHealthProfileTestOrder = (YellowstonePathology.Business.Test.WomensHealthProfile.WomensHealthProfileTestOrder)accessionOrder.PanelSetOrderCollection.GetPanelSetOrder(this.m_WomensHealthProfileTest.PanelSetId);
                this.m_WomensHealthProfileVisibility = System.Windows.Visibility.Visible;
                this.UpdateWomensHealthProfile();
            }
            else
            {
                this.m_WomensHealthProfileVisibility = System.Windows.Visibility.Collapsed;
            }

            this.m_AccessionOrderList = new List<Business.Test.AccessionOrder>();
            this.m_AccessionOrderList.Add(this.m_AccessionOrder);

            InitializeComponent();

            DataContext = this;
        }
Ejemplo n.º 12
0
 public EpicStatusMessage(string clientOrderId, OrderStatus orderStatus, YellowstonePathology.Business.ClientOrder.Model.UniversalService universalService, object writer)
 {
     this.m_ClientOrder       = YellowstonePathology.Business.Persistence.DocumentGateway.Instance.PullClientOrderByClientOrderId(clientOrderId, writer);
     this.m_OrderingPhysician = YellowstonePathology.Business.Gateway.PhysicianClientGateway.GetPhysicianByNpi(this.m_ClientOrder.ProviderId);
     this.m_OrderStatus       = orderStatus;
     this.m_UniversalService  = universalService;
     this.SetupFileNames();
 }
Ejemplo n.º 13
0
 private void HandleProviderMapping()
 {
     if (this.m_ClientOrder.SystemInitiatingOrder == "EPIC")
     {
         this.m_Physician = YellowstonePathology.Business.Gateway.PhysicianClientGateway.GetPhysicianByNpi(this.m_ClientOrder.ProviderId);
         this.NotifyPropertyChanged("Physician");
     }
 }
Ejemplo n.º 14
0
 public EpicStatusMessage(string clientOrderId, OrderStatus orderStatus, YellowstonePathology.Business.ClientOrder.Model.UniversalService universalService, object writer)
 {
     this.m_ClientOrder = YellowstonePathology.Business.Persistence.DocumentGateway.Instance.PullClientOrderByClientOrderId(clientOrderId, writer);
     this.m_OrderingPhysician = YellowstonePathology.Business.Gateway.PhysicianClientGateway.GetPhysicianByNpi(this.m_ClientOrder.ProviderId);
     this.m_OrderStatus = orderStatus;
     this.m_UniversalService = universalService;
     this.SetupFileNames();
 }
Ejemplo n.º 15
0
 public EpicStatusMessage(YellowstonePathology.Business.ClientOrder.Model.ClientOrder clientOrder, OrderStatus orderStatus, YellowstonePathology.Business.ClientOrder.Model.UniversalService universalService)
 {
     this.m_ClientOrder = clientOrder;
     this.m_OrderingPhysician = YellowstonePathology.Business.Gateway.PhysicianClientGateway.GetPhysicianByNpi(this.m_ClientOrder.ProviderId);
     this.m_OrderStatus = orderStatus;
     this.m_UniversalService = universalService;
     this.SetupFileNames();
 }
Ejemplo n.º 16
0
 public EpicStatusMessage(YellowstonePathology.Business.ClientOrder.Model.ClientOrder clientOrder, OrderStatus orderStatus, YellowstonePathology.Business.ClientOrder.Model.UniversalService universalService)
 {
     this.m_ClientOrder       = clientOrder;
     this.m_OrderingPhysician = YellowstonePathology.Business.Gateway.PhysicianClientGateway.GetPhysicianByNpi(this.m_ClientOrder.ProviderId);
     this.m_OrderStatus       = orderStatus;
     this.m_UniversalService  = universalService;
     this.SetupFileNames();
 }
Ejemplo n.º 17
0
 public MTDohOrcView(string externalOrderId, YellowstonePathology.Business.Domain.Physician orderingPhysician, string reportNo, OrderStatus orderStatus, string systemInitiatingOrder)
 {
     this.m_ExternalOrderId       = externalOrderId;
     this.m_OrderingPhysician     = orderingPhysician;
     this.m_ReportNo              = reportNo;
     this.m_OrderStatus           = orderStatus;
     this.m_SystemInitiatingOrder = systemInitiatingOrder;
 }
Ejemplo n.º 18
0
 public OrcView(string externalOrderId, YellowstonePathology.Business.Domain.Physician orderingPhysician, string reportNo, OrderStatus orderStatus, string systemInitiatingOrder)
 {
     this.m_ExternalOrderId = externalOrderId;
     this.m_OrderingPhysician = orderingPhysician;
     this.m_ReportNo = reportNo;
     this.m_OrderStatus = orderStatus;
     this.m_SystemInitiatingOrder = systemInitiatingOrder;
 }
Ejemplo n.º 19
0
 public ECWORCView(string externalOrderId, YellowstonePathology.Business.Domain.Physician orderingPhysician, string masterAccessionNo, OrderStatus orderStatus, string systemInitiatingOrder, bool sendUnsolicited)
 {
     this.m_ExternalOrderId = externalOrderId;
     this.m_OrderingPhysician = orderingPhysician;
     this.m_MasterAccessionNo = masterAccessionNo;
     this.m_OrderStatus = orderStatus;
     this.m_SystemInitiatingOrder = systemInitiatingOrder;
     this.m_SendUnsolicited = sendUnsolicited;
 }
Ejemplo n.º 20
0
 public WYDOHORCView(string externalOrderId, Business.Client.Model.Client client, YellowstonePathology.Business.Domain.Physician orderingPhysician, string reportNo, OrderStatus orderStatus, string systemInitiatingOrder)
 {
     this.m_ExternalOrderId       = externalOrderId;
     this.m_Client                = client;
     this.m_OrderingPhysician     = orderingPhysician;
     this.m_ReportNo              = reportNo;
     this.m_OrderStatus           = orderStatus;
     this.m_SystemInitiatingOrder = systemInitiatingOrder;
 }
        public WomensHealthProfilePage(YellowstonePathology.Business.Test.WomensHealthProfile.WomensHealthProfileTestOrder womensHealthProfileTestOrder,
                                       YellowstonePathology.Business.Test.AccessionOrder accessionOrder,
                                       YellowstonePathology.Business.ClientOrder.Model.ClientOrder clientOrder,
                                       System.Windows.Visibility backButtonVisibility) : base(womensHealthProfileTestOrder, accessionOrder)
        {
            this.m_AccessionOrder = accessionOrder;

            this.m_HPVReflexOrderCollection       = YellowstonePathology.Business.Client.Model.ReflexOrderCollection.GetHPVRequisitionReflexOrders();
            this.m_HPVStandingOrderCollection     = YellowstonePathology.Business.Client.Model.StandingOrderCollection.GetHPVStandingOrders();
            this.m_HPV1618ReflexOrderCollection   = YellowstonePathology.Business.Client.Model.ReflexOrderCollection.GetHPV1618ReflexOrders();
            this.m_HPV1618StandingOrderCollection = YellowstonePathology.Business.Client.Model.StandingOrderCollection.GetHPV1618StandingOrders();

            this.m_ClientOrder = clientOrder;
            this.m_WomensHealthProfileTestOrder = womensHealthProfileTestOrder;
            this.m_SystemIdentity       = Business.User.SystemIdentity.Instance;
            this.m_BackButtonVisibility = backButtonVisibility;

            this.m_Physician = YellowstonePathology.Business.Gateway.PhysicianClientGateway.GetPhysicianByPhysicianId(this.m_AccessionOrder.PhysicianId);

            this.m_PanelSetOrderCytology = (YellowstonePathology.Business.Test.ThinPrepPap.PanelSetOrderCytology)accessionOrder.PanelSetOrderCollection.GetPanelSetOrder(15);

            this.m_AuditCollection = new Business.Audit.Model.IsWHPAllDoneAuditCollection(this.m_AccessionOrder);
            this.m_AuditCollection.Run();

            if (string.IsNullOrEmpty(accessionOrder.PatientId) == false)
            {
                YellowstonePathology.Business.Domain.PatientHistory patientHistory = YellowstonePathology.Business.Gateway.AccessionOrderGateway.GetPatientHistory(accessionOrder.PatientId);
                this.m_DateOfLastHPV = patientHistory.GetDateOfPreviousHpv(this.m_AccessionOrder.AccessionDate.Value);
            }

            YellowstonePathology.Business.Client.Model.StandingOrder standingOrder = YellowstonePathology.Business.Client.Model.StandingOrderCollection.GetByStandingOrderCode(this.m_WomensHealthProfileTestOrder.HPVStandingOrderCode);
            this.m_HPVStandingOrderDescription = standingOrder.ToString();

            InitializeComponent();

            this.DataContext = this;

            this.m_ParentWindow = Window.GetWindow(this);

            this.m_ControlsNotDisabledOnFinal.Add(this.ButtonClose);
            this.m_ControlsNotDisabledOnFinal.Add(this.ButtonBack);
            this.m_ControlsNotDisabledOnFinal.Add(this.TextBlockShowDocument);
            this.m_ControlsNotDisabledOnFinal.Add(this.TextBlockUnfinalize);
            this.m_ControlsNotDisabledOnFinal.Add(this.TextBlockNext);

            this.m_ControlsNotEnabledOnUnFinal.Add(this.CheckBoxAccepted);
            this.m_ControlsNotEnabledOnUnFinal.Add(this.CheckBoxFinal);
            this.m_ControlsNotEnabledOnUnFinal.Add(this.ComboBoxStandingOrderDescription);
            this.m_ControlsNotEnabledOnUnFinal.Add(this.TextBlockLastHPVDate);
            this.m_ControlsNotEnabledOnUnFinal.Add(this.TextBlockPatientAge);
            this.m_ControlsNotEnabledOnUnFinal.Add(this.TextBlockScreeningImpression);
            this.m_ControlsNotEnabledOnUnFinal.Add(this.TextBlockStandingOrderDescription);
            this.m_ControlsNotEnabledOnUnFinal.Add(this.TextBoxAcceptedBy);
            this.m_ControlsNotEnabledOnUnFinal.Add(this.TextBoxAcceptedTime);
            this.m_ControlsNotEnabledOnUnFinal.Add(this.TextBoxFinalTime);
            this.m_ControlsNotEnabledOnUnFinal.Add(this.TextBoxSignaure);
        }
Ejemplo n.º 22
0
 public EPICOrcView(string externalOrderId, YellowstonePathology.Business.Domain.Physician orderingPhysician, string masterAccessionNo, OrderStatus orderStatus, string systemInitiatingOrder, bool sendUnsolicited)
 {
     this.m_ExternalOrderId       = externalOrderId;
     this.m_OrderingPhysician     = orderingPhysician;
     this.m_MasterAccessionNo     = masterAccessionNo;
     this.m_OrderStatus           = orderStatus;
     this.m_SystemInitiatingOrder = systemInitiatingOrder;
     this.m_SendUnsolicited       = sendUnsolicited;
 }
Ejemplo n.º 23
0
        public EPICFT1ResultView(Business.Test.AccessionOrder accessionOrder, Business.Test.PanelSetOrderCPTCodeBill panelSetOrderCPTCodeBill, bool testing)
        {
            this.m_Testing = testing;
            this.m_AccessionOrder = accessionOrder;
            this.m_PanelSetOrderCPTCodeBill = panelSetOrderCPTCodeBill;

            this.m_CptCode = Business.Billing.Model.CptCodeCollection.Instance.GetCptCode(this.m_PanelSetOrderCPTCodeBill.CPTCode);
            this.m_OrderingPhysician = YellowstonePathology.Business.Gateway.PhysicianClientGateway.GetPhysicianByPhysicianId(this.m_AccessionOrder.PhysicianId);
        }
Ejemplo n.º 24
0
 public EPICFT1View(YellowstonePathology.Business.Billing.Model.CptCode cptCode, DateTime billDate, DateTime postDate, string quantity,
     YellowstonePathology.Business.Domain.Physician orderingPhysician)
 {
     this.m_CptCode = cptCode;
     this.m_BillDate = billDate;
     this.m_PostDate = postDate;
     this.m_Quantity = quantity;
     this.m_OrderingPhysician = orderingPhysician;
 }
Ejemplo n.º 25
0
 private void SetPhysician(YellowstonePathology.Business.Client.PhysicianClient physicianClient)
 {
     YellowstonePathology.Business.Domain.Physician physician = YellowstonePathology.Business.Gateway.PhysicianClientGateway.GetPhysicianByPhysicianId(physicianClient.PhysicianId);
     if (physician != null)
     {
         this.m_ClientOrder.ProviderId   = physician.Npi;
         this.m_ClientOrder.ProviderName = physician.FirstName + ' ' + physician.LastName;
         this.SetProviderStatusColor();
     }
 }
        public BigSkyDermatologyResultView(string reportNo, OrderStatus orderStatus, object writer)
        {
            this.m_ReportNo = reportNo;
            this.m_OrderStatus = orderStatus;

            string masterAccessionNo = YellowstonePathology.Business.Gateway.AccessionOrderGateway.GetMasterAccessionNoFromReportNo(this.m_ReportNo);
            this.m_AccessionOrder = YellowstonePathology.Business.Persistence.DocumentGateway.Instance.PullAccessionOrder(masterAccessionNo, writer);

            this.m_OrderingPhysician = YellowstonePathology.Business.Gateway.PhysicianClientGateway.GetPhysicianByPhysicianId(this.m_AccessionOrder.PhysicianId);
        }
Ejemplo n.º 27
0
        public static Domain.Physician GetPhysicianByNpi(string npi)
        {
            YellowstonePathology.Business.Domain.Physician result = new YellowstonePathology.Business.Domain.Physician();
            YellowstonePathology.Business.Mongo.Server     server = new Business.Mongo.TestServer(YellowstonePathology.Business.Mongo.MongoTestServer.LISDatabaseName);
            MongoCollection collection   = server.Database.GetCollection <BsonDocument>("Physician");
            BsonDocument    bsonDocument = collection.FindOneAs <BsonDocument>(Query.EQ("Npi", BsonValue.Create(npi)));

            YellowstonePathology.Business.Mongo.BSONPropertyWriter.Write(bsonDocument, result);
            return(result);
        }
Ejemplo n.º 28
0
 public ObrView(string externalOrderId, string ypiOrderId, Nullable<DateTime> accessionTime, Nullable<DateTime> finalTime, 
     YellowstonePathology.Business.Domain.Physician orderingPhysician, string observationResultStatus)
 {
     this.m_ExternalOrderId = externalOrderId;
     this.m_YpiOrderId = ypiOrderId;
     this.m_AccessionTime = accessionTime;
     this.m_FinalTime = finalTime;
     this.m_OrderingPhysician = orderingPhysician;
     this.m_ObservationResultStatus = observationResultStatus;
 }
Ejemplo n.º 29
0
 public ObrView(string externalOrderId, string ypiOrderId, Nullable <DateTime> accessionTime, Nullable <DateTime> finalTime,
                YellowstonePathology.Business.Domain.Physician orderingPhysician, string observationResultStatus)
 {
     this.m_ExternalOrderId         = externalOrderId;
     this.m_YpiOrderId              = ypiOrderId;
     this.m_AccessionTime           = accessionTime;
     this.m_FinalTime               = finalTime;
     this.m_OrderingPhysician       = orderingPhysician;
     this.m_ObservationResultStatus = observationResultStatus;
 }
Ejemplo n.º 30
0
        public static bool IsNPIValid(string npi)
        {
            bool result = true;

            YellowstonePathology.Business.Domain.Physician physician = YellowstonePathology.Business.Gateway.PhysicianClientGateway.GetPhysicianByNpi(npi);
            if (physician == null)
            {
                result = false;
            }
            return(result);
        }
Ejemplo n.º 31
0
 public EPICStatusObrView(string externalOrderId, string ypiOrderId, Nullable <DateTime> accessionTime, Nullable <DateTime> finalTime,
                          YellowstonePathology.Business.Domain.Physician orderingPhysician, string observationResultStatus, YellowstonePathology.Business.ClientOrder.Model.UniversalService universalService)
 {
     this.m_ExternalOrderId         = externalOrderId;
     this.m_YpiOrderId              = ypiOrderId;
     this.m_AccessionTime           = accessionTime;
     this.m_FinalTime               = finalTime;
     this.m_OrderingPhysician       = orderingPhysician;
     this.m_ObservationResultStatus = observationResultStatus;
     this.m_UniversalService        = universalService;
 }
Ejemplo n.º 32
0
 public EPICStatusMessage(YellowstonePathology.Business.ClientOrder.Model.ClientOrder clientOrder, OrderStatus orderStatus,
                          YellowstonePathology.Business.ClientOrder.Model.UniversalService universalService, string resultMessage, string resultStatus, DateTime dateOfService)
 {
     this.m_ClientOrder       = clientOrder;
     this.m_OrderingPhysician = YellowstonePathology.Business.Gateway.PhysicianClientGateway.GetPhysicianByNpi(this.m_ClientOrder.ProviderId);
     this.m_OrderStatus       = orderStatus;
     this.m_UniversalService  = universalService;
     this.m_ResultMessage     = resultMessage;
     this.m_ResultStatus      = resultStatus;
     this.m_DateOfService     = dateOfService;
 }
Ejemplo n.º 33
0
 public EpicStatusObrView(string externalOrderId, string ypiOrderId, Nullable<DateTime> accessionTime, Nullable<DateTime> finalTime, 
     YellowstonePathology.Business.Domain.Physician orderingPhysician, string observationResultStatus, YellowstonePathology.Business.ClientOrder.Model.UniversalService universalService)
 {
     this.m_ExternalOrderId = externalOrderId;
     this.m_YpiOrderId = ypiOrderId;
     this.m_AccessionTime = accessionTime;
     this.m_FinalTime = finalTime;
     this.m_OrderingPhysician = orderingPhysician;
     this.m_ObservationResultStatus = observationResultStatus;
     this.m_UniversalService = universalService;
 }
        public BigSkyDermatologyResultView(string reportNo, OrderStatus orderStatus, object writer)
        {
            this.m_ReportNo    = reportNo;
            this.m_OrderStatus = orderStatus;

            string masterAccessionNo = YellowstonePathology.Business.Gateway.AccessionOrderGateway.GetMasterAccessionNoFromReportNo(this.m_ReportNo);

            this.m_AccessionOrder = YellowstonePathology.Business.Persistence.DocumentGateway.Instance.PullAccessionOrder(masterAccessionNo, writer);

            this.m_OrderingPhysician = YellowstonePathology.Business.Gateway.PhysicianClientGateway.GetPhysicianByPhysicianId(this.m_AccessionOrder.PhysicianId);
        }
Ejemplo n.º 35
0
        private void ListBoxProviders_MouseDoubleClick(object sender, MouseButtonEventArgs e)
        {
            if (this.ListViewProviders.SelectedItem != null)
            {
                YellowstonePathology.Business.Client.Model.ProviderClient providerClient = (YellowstonePathology.Business.Client.Model.ProviderClient) this.ListViewProviders.SelectedItem;
                YellowstonePathology.Business.Domain.Physician            physician      = YellowstonePathology.Business.Persistence.DocumentGateway.Instance.PullPhysician(providerClient.Physician.PhysicianId, this);

                ProviderEntry providerEntry = new ProviderEntry(physician);
                providerEntry.ShowDialog();
            }
        }
Ejemplo n.º 36
0
        private void ListBoxProviders_MouseDoubleClick(object sender, MouseButtonEventArgs e)
        {
            if (this.ListViewProviders.SelectedItem != null)
            {
                YellowstonePathology.Business.Client.Model.ProviderClient providerClient = (YellowstonePathology.Business.Client.Model.ProviderClient) this.ListViewProviders.SelectedItem;
                YellowstonePathology.Business.Domain.Physician            physician      = providerClient.Physician;

                ProviderEntry providerEntry = new ProviderEntry(physician, false);
                providerEntry.ShowDialog();
            }
        }
Ejemplo n.º 37
0
        public void PullPhysician(YellowstonePathology.Business.Domain.Physician physician, object writer)
        {
            SqlCommand cmd = new SqlCommand();

            cmd.CommandText = "select * From tblPhysician where PhysicianId = @PhysicianId";
            cmd.CommandType = CommandType.Text;
            cmd.Parameters.Add("@PhysicianId", SqlDbType.Int).Value = physician.PhysicianId;
            GenericDocumentBuilder builder = new GenericDocumentBuilder(cmd, typeof(YellowstonePathology.Business.Domain.Physician));

            DocumentId documentId = new DocumentId(physician, writer);
            Document   document   = this.m_Stack.Pull(documentId, builder);
        }
Ejemplo n.º 38
0
        public void Publish(string basePath)
        {
            XElement document = new XElement("HL7Message");

            Hl7Client client = null;

            YellowstonePathology.Business.Client.Model.ClientGroupClientCollection hrhGroup = YellowstonePathology.Business.Gateway.PhysicianClientGateway.GetClientGroupClientCollectionByClientGroupId("2");
            if (hrhGroup.ClientIdExists(this.m_AccessionOrder.ClientId) == true)
            {
                client = new EPICHRHClient();
            }
            else
            {
                client = new EPICHl7Client();
            }

            DFTP03 messageType = new DFTP03();

            YellowstonePathology.Business.Domain.Physician orderingPhysician = YellowstonePathology.Business.Gateway.PhysicianClientGateway.GetPhysicianByPhysicianId(this.m_AccessionOrder.PhysicianId);

            string locationCode = "YPIIBILLINGS";

            if (this.m_PanelSetOrderCPTCodeBill.MedicalRecord.StartsWith("A") == true)
            {
                throw new Exception("Cant send CDM for an A Number: " + this.m_AccessionOrder.SvhMedicalRecord);
            }

            EPICMshView msh = new EPICMshView(client, messageType, locationCode);

            msh.ToXml(document);

            EpicPidView pid = new EpicPidView(this.m_PanelSetOrderCPTCodeBill.MedicalRecord, this.m_AccessionOrder.PLastName, this.m_AccessionOrder.PFirstName, this.m_AccessionOrder.PBirthdate,
                                              this.m_AccessionOrder.PSex, this.m_PanelSetOrderCPTCodeBill.Account, this.m_AccessionOrder.PSSN);

            pid.ToXml(document);

            Business.Billing.Model.CptCode cptCode = Store.AppDataStore.Instance.CPTCodeCollection.GetClone(this.m_PanelSetOrderCPTCodeBill.CPTCode, this.m_PanelSetOrderCPTCodeBill.Modifier);

            DateTime transactionDate        = m_AccessionOrder.CollectionDate.Value;
            DateTime transactionPostingDate = this.m_PanelSetOrderCPTCodeBill.PostDate.Value;

            EPICFT1View epicFT1View = new EPICFT1View(cptCode, transactionDate, transactionPostingDate, this.m_PanelSetOrderCPTCodeBill.Quantity.ToString(), orderingPhysician, this.m_AccessionOrder.MasterAccessionNo);

            epicFT1View.ToXml(document, 1);

            string fileName = System.IO.Path.Combine(basePath, this.m_PanelSetOrderCPTCodeBill.PanelSetOrderCPTCodeBillId + "." + cptCode.Code + ".hl7.xml");

            using (System.IO.StreamWriter sw = new System.IO.StreamWriter(fileName))
            {
                document.Save(sw);
            }
        }
Ejemplo n.º 39
0
        public EPICResultView(string reportNo, Business.Test.AccessionOrder accessionOrder, bool testing)
        {
            this.m_Testing = testing;
            this.m_AccessionOrder = accessionOrder;
            this.m_PanelSetOrder = this.m_AccessionOrder.PanelSetOrderCollection.GetPanelSetOrder(reportNo);

            if (this.m_AccessionOrder.UniversalServiceId.ToUpper() != this.m_PanelSetOrder.UniversalServiceId.ToUpper())
            {
                this.m_SendUnsolicited = true;
            }

            this.m_OrderingPhysician = YellowstonePathology.Business.Gateway.PhysicianClientGateway.GetPhysicianByPhysicianId(this.m_AccessionOrder.PhysicianId);
        }
Ejemplo n.º 40
0
        public EPICBeakerResultView(string reportNo, Business.Test.AccessionOrder accessionOrder, bool testing)
        {
            this.m_Testing        = testing;
            this.m_AccessionOrder = accessionOrder;
            this.m_PanelSetOrder  = this.m_AccessionOrder.PanelSetOrderCollection.GetPanelSetOrder(reportNo);

            if (string.IsNullOrEmpty(this.m_PanelSetOrder.ExternalOrderId) == true)
            {
                this.m_SendUnsolicited = true;
            }

            this.m_OrderingPhysician = YellowstonePathology.Business.Gateway.PhysicianClientGateway.GetPhysicianByPhysicianId(this.m_AccessionOrder.PhysicianId);
        }
Ejemplo n.º 41
0
        public EpicResultView(string reportNo, Business.Test.AccessionOrder accessionOrder, bool testing)
        {
            this.m_Testing        = testing;
            this.m_AccessionOrder = accessionOrder;
            this.m_PanelSetOrder  = this.m_AccessionOrder.PanelSetOrderCollection.GetPanelSetOrder(reportNo);

            if (this.m_AccessionOrder.UniversalServiceId.ToUpper() != this.m_PanelSetOrder.UniversalServiceId.ToUpper())
            {
                this.m_SendUnsolicited = true;
            }

            this.m_OrderingPhysician = YellowstonePathology.Business.Gateway.PhysicianClientGateway.GetPhysicianByPhysicianId(this.m_AccessionOrder.PhysicianId);
        }
Ejemplo n.º 42
0
 private void ButtonAddToClient_Click(object sender, RoutedEventArgs e)
 {
     if (this.ListBoxAvailableProviders.SelectedItem != null)
     {
         YellowstonePathology.Business.Domain.Physician physician = (YellowstonePathology.Business.Domain.Physician) this.ListBoxAvailableProviders.SelectedItem;
         if (this.m_ClientPhysicianView.PhysicianExists(physician.PhysicianId) == false)
         {
             string objectId = MongoDB.Bson.ObjectId.GenerateNewId().ToString();
             YellowstonePathology.Business.Domain.PhysicianClient physicianClient = new Business.Domain.PhysicianClient(objectId, objectId, physician.PhysicianId, physician.ObjectId, this.m_Client.ClientId);
             YellowstonePathology.Business.Persistence.DocumentGateway.Instance.InsertDocument(physicianClient, this);
             this.m_ClientPhysicianView.Physicians.Add(physician);
             this.NotifyPropertyChanged("Physicians");
         }
     }
 }
Ejemplo n.º 43
0
 public ECWOBRView(string externalOrderId, string masterAccessionNo, string reportNo, Nullable<DateTime> collectionDate, Nullable<DateTime> collectionTime, Nullable<DateTime> accessionTime, Nullable<DateTime> finalTime,
     YellowstonePathology.Business.Domain.Physician orderingPhysician, string observationResultStatus, YellowstonePathology.Business.ClientOrder.Model.UniversalService universalService, bool sendUnsolicited)
 {
     this.m_ExternalOrderId = externalOrderId;
     this.m_MasterAccessionNo = masterAccessionNo;
     this.m_ReportNo = reportNo;
     this.m_CollectionTime = collectionTime;
     this.m_CollectionDate = collectionDate;
     this.m_AccessionTime = accessionTime;
     this.m_FinalTime = finalTime;
     this.m_OrderingPhysician = orderingPhysician;
     this.m_ObservationResultStatus = observationResultStatus;
     this.m_UniversalService = universalService;
     this.m_SendUnsolicited = sendUnsolicited;
 }
Ejemplo n.º 44
0
        public ProviderEntry(YellowstonePathology.Business.Domain.Physician physician)
        {
            this.m_Physician = physician;

            this.m_SystemIdentity = Business.User.SystemIdentity.Instance;
            this.m_PhysicianClientView = YellowstonePathology.Business.Gateway.PhysicianClientGateway.GetPhysicianClientView(this.m_Physician.ObjectId);
            this.m_HpvStandingOrders = YellowstonePathology.Business.Client.Model.StandingOrderCollection.GetHPVStandingOrders();
            this.m_HPV1618StandingOrderCollection = YellowstonePathology.Business.Client.Model.StandingOrderCollection.GetHPV1618StandingOrders();
            this.m_ClientCollection = new YellowstonePathology.Business.Client.Model.ClientCollection();

            InitializeComponent();

            this.m_ParentWindow = Window.GetWindow(this);
            this.DataContext = this;
            Loaded += ProviderEntry_Loaded;
            Closing += ProviderEntry_Closing;
        }
        public WomensHealthProfilePage(YellowstonePathology.Business.Test.WomensHealthProfile.WomensHealthProfileTestOrder womensHealthProfileTestOrder,
            YellowstonePathology.Business.Test.AccessionOrder accessionOrder,
            YellowstonePathology.Business.ClientOrder.Model.ClientOrder clientOrder, 
            System.Windows.Visibility backButtonVisibility)
            : base(womensHealthProfileTestOrder, accessionOrder)
        {
            this.m_AccessionOrder = accessionOrder;

            this.m_HPVReflexOrderCollection = YellowstonePathology.Business.Client.Model.ReflexOrderCollection.GetHPVRequisitionReflexOrders();
            this.m_HPVStandingOrderCollection = YellowstonePathology.Business.Client.Model.StandingOrderCollection.GetHPVStandingOrders();
            this.m_HPV1618ReflexOrderCollection = YellowstonePathology.Business.Client.Model.ReflexOrderCollection.GetHPV1618ReflexOrders();
            this.m_HPV1618StandingOrderCollection = YellowstonePathology.Business.Client.Model.StandingOrderCollection.GetHPV1618StandingOrders();

            this.m_ClientOrder = clientOrder;
            this.m_WomensHealthProfileTestOrder = womensHealthProfileTestOrder;
            this.m_SystemIdentity = Business.User.SystemIdentity.Instance;
            this.m_BackButtonVisibility = backButtonVisibility;

            this.m_Physician = YellowstonePathology.Business.Gateway.PhysicianClientGateway.GetPhysicianByPhysicianId(this.m_AccessionOrder.PhysicianId);

            this.m_PanelSetOrderCytology = (YellowstonePathology.Business.Test.ThinPrepPap.PanelSetOrderCytology)accessionOrder.PanelSetOrderCollection.GetPanelSetOrder(15);

            this.m_AuditCollection = new Business.Audit.Model.IsWHPAllDoneAuditCollection(this.m_AccessionOrder);
            this.m_AuditCollection.Run();

            if (string.IsNullOrEmpty(accessionOrder.PatientId) == false)
            {
                YellowstonePathology.Business.Domain.PatientHistory patientHistory = YellowstonePathology.Business.Gateway.AccessionOrderGateway.GetPatientHistory(accessionOrder.PatientId);
                this.m_DateOfLastHPV = patientHistory.GetDateOfPreviousHpv(this.m_AccessionOrder.AccessionDate.Value);
            }

            YellowstonePathology.Business.Client.Model.StandingOrder standingOrder = YellowstonePathology.Business.Client.Model.StandingOrderCollection.GetByStandingOrderCode(this.m_WomensHealthProfileTestOrder.HPVStandingOrderCode);
            this.m_HPVStandingOrderDescription = standingOrder.ToString();

            InitializeComponent();

            this.DataContext = this;

            this.m_ParentWindow = Window.GetWindow(this);

            this.m_ControlsNotDisabledOnFinal.Add(this.ButtonClose);
            this.m_ControlsNotDisabledOnFinal.Add(this.ButtonBack);
            this.m_ControlsNotDisabledOnFinal.Add(this.TextBlockShowDocument);
            this.m_ControlsNotDisabledOnFinal.Add(this.TextBlockUnfinalize);
            this.m_ControlsNotDisabledOnFinal.Add(this.TextBlockNext);
        }
Ejemplo n.º 46
0
        public MTDohObrView(YellowstonePathology.Business.Test.AccessionOrder accessionOrder, string reportNo, YellowstonePathology.Business.Domain.Physician orderingPhysician)
        {
            this.m_AccessionOrder = accessionOrder;
            this.m_ReportNo = reportNo;
            this.m_OrderingPhysician = orderingPhysician;

            YellowstonePathology.Business.Test.PanelSetOrder panelSetOrder = this.m_AccessionOrder.PanelSetOrderCollection.GetPanelSetOrder(13);
            this.m_SigningPathologist = YellowstonePathology.Business.User.SystemUserCollectionInstance.Instance.SystemUserCollection.GetSystemUserById(panelSetOrder.AssignedToId);

            if (panelSetOrder.AmendmentCollection.Count == 0)
            {
                this.m_ObservationResultStatus = "F";
            }
            else
            {
                this.m_ObservationResultStatus = "C";
            }
        }
Ejemplo n.º 47
0
 public EpicStatusOrcView(string externalOrderId, YellowstonePathology.Business.Domain.Physician orderingPhysician, OrderStatus orderStatus)
 {
     this.m_ExternalOrderId = externalOrderId;
     this.m_OrderingPhysician = orderingPhysician;
     this.m_OrderStatus = orderStatus;
 }
 public HPV1618StandingOrderHandler(YellowstonePathology.Business.Domain.Physician physician, YellowstonePathology.Business.Test.PanelSetOrderCollection panelSetOrderCollection)
     : base(panelSetOrderCollection)
 {
     this.m_Physician = physician;
     this.Initialize();
 }
Ejemplo n.º 49
0
 public ORC(string reportNo, YellowstonePathology.Business.Test.AccessionOrder accessionOrder, YellowstonePathology.Business.Domain.Physician orderingPhysician)
 {
     this.m_ReportNo = reportNo;
     this.m_AccessionOrder = accessionOrder;
     this.m_OrderingPhysician = orderingPhysician;
 }
 public static Domain.Physician GetPhysicianByPhysicianId(int physicianId)
 {
     YellowstonePathology.Business.Domain.Physician result = new YellowstonePathology.Business.Domain.Physician();
     YellowstonePathology.Business.Mongo.Server server = new Business.Mongo.TestServer(YellowstonePathology.Business.Mongo.MongoTestServer.LISDatabaseName);
     MongoCollection collection = server.Database.GetCollection<BsonDocument>("Physician");
     BsonDocument bsonDocument = collection.FindOneAs<BsonDocument>(Query.EQ("PhysicianId", BsonValue.Create(physicianId)));
     YellowstonePathology.Business.Mongo.BSONPropertyWriter.Write(bsonDocument, result);
     return result;
 }
        public static Domain.PhysicianCollection GetPhysiciansByName(string firstName, string lastName)
        {
            YellowstonePathology.Business.Domain.PhysicianCollection result = new YellowstonePathology.Business.Domain.PhysicianCollection();
            YellowstonePathology.Business.Mongo.Server server = new Business.Mongo.TestServer(YellowstonePathology.Business.Mongo.MongoTestServer.LISDatabaseName);
            MongoCollection collection = server.Database.GetCollection<BsonDocument>("Physician");
            MongoCursor cursor = null;
            if (string.IsNullOrEmpty(firstName) == false)
            {
                cursor = collection.FindAs<BsonDocument>(Query.And(Query.Matches("LastName", BsonRegularExpression.Create("^" + lastName + ".*", "i")),
                    Query.Matches("FirstName", BsonRegularExpression.Create("^" + firstName + ".*", "i")))).SetSortOrder(SortBy.Ascending("LastName", "FirstName"));
            }
            else
            {
                cursor = collection.FindAs<BsonDocument>(Query.Matches("LastName", BsonRegularExpression.Create("^" + lastName + ".*", "i"))).SetSortOrder(SortBy.Ascending("LastName", "FirstName"));
            }

            foreach (BsonDocument bsonDocument in cursor)
            {
                YellowstonePathology.Business.Domain.Physician physician = new YellowstonePathology.Business.Domain.Physician();
                YellowstonePathology.Business.Mongo.BSONPropertyWriter.Write(bsonDocument, physician);
                result.Add(physician);
            }

            return result;
        }
Ejemplo n.º 52
0
 public ProviderNpiAudit(YellowstonePathology.Business.Domain.Physician physician)
 {
     this.m_Physician = physician;
 }
        public static View.ClientPhysicianView GetClientPhysicianViewByClientId(int clientId)
        {
            YellowstonePathology.Business.View.ClientPhysicianView result = new YellowstonePathology.Business.View.ClientPhysicianView();
            YellowstonePathology.Business.Mongo.Server server = new Business.Mongo.TestServer(YellowstonePathology.Business.Mongo.MongoTestServer.LISDatabaseName);
            MongoCollection clientCollection = server.Database.GetCollection<BsonDocument>("Client");
            BsonDocument clientBsonDocument = clientCollection.FindOneAs<BsonDocument>(Query.EQ("ClientId", BsonValue.Create(clientId)));
            YellowstonePathology.Business.Mongo.BSONPropertyWriter.Write(clientBsonDocument, result);

            MongoCollection physicianClientCollection = server.Database.GetCollection<BsonDocument>("PhysicianClient");
            MongoCursor physicianClientCursor = physicianClientCollection.FindAs<BsonDocument>(Query.EQ("ClientId", BsonValue.Create(clientId)));
            List<BsonValue> physicianIdList = new List<BsonValue>();
            foreach (BsonDocument bsonDocument in physicianClientCursor)
            {
                physicianIdList.Add(bsonDocument.GetValue("PhysicianId"));
            }

            MongoCollection physicianCollection = server.Database.GetCollection<BsonDocument>("Physician");
            MongoCursor physicianCursor = physicianCollection.FindAs<BsonDocument>(Query.In("PhysicianId", physicianIdList)).SetSortOrder(SortBy.Ascending("FirstName"));
            foreach (BsonDocument bsonDocument in physicianCursor)
            {
                YellowstonePathology.Business.Domain.Physician physician = new YellowstonePathology.Business.Domain.Physician();
                YellowstonePathology.Business.Mongo.BSONPropertyWriter.Write(bsonDocument, physician);
                result.Physicians.Add(physician);
            }

            return result;
        }
Ejemplo n.º 54
0
 private void HandleProviderMapping()
 {
     if (this.m_ClientOrder.SystemInitiatingOrder == "EPIC")
     {
         this.m_Physician = YellowstonePathology.Business.Gateway.PhysicianClientGateway.GetPhysicianByNpi(this.m_ClientOrder.ProviderId);
         this.NotifyPropertyChanged("Physician");
     }
 }
Ejemplo n.º 55
0
 public PV1(YellowstonePathology.Business.Test.AccessionOrder accessionOrder, YellowstonePathology.Business.Domain.Physician attendingPhysician)
 {
     this.m_AccessionOrder = accessionOrder;
     this.m_AttendingPhysician = attendingPhysician;
 }