public ProcessorSelectionPage(YellowstonePathology.Business.Specimen.Model.SpecimenOrder specimenOrder) { this.m_SpecimenOrder = specimenOrder; this.m_ProcessorRunCollection = Business.Surgical.ProcessorRunCollection.GetAll(false); InitializeComponent(); DataContext = this; this.ListBoxProcessorRun.SelectionChanged += new SelectionChangedEventHandler(ListBoxProcessorRun_SelectionChanged); }
public FixationDetailsPage(YellowstonePathology.Business.Test.AccessionOrder accessionOrder) { this.m_AccessionOrder = accessionOrder; this.m_ProcessorRunCollection = Business.Surgical.ProcessorRunCollection.GetAll(); this.m_FixationTypeCollection = YellowstonePathology.Business.Specimen.Model.FixationType.GetFixationTypeCollection(); this.m_TimeToFixationTypeCollection = YellowstonePathology.Business.Specimen.Model.TimeToFixationType.GetTimeToFixationTypeCollection(); YellowstonePathology.Business.ClientOrder.Model.ClientOrderCollection clientOrderCollection = YellowstonePathology.Business.Gateway.ClientOrderGateway.GetClientOrdersByMasterAccessionNo(this.m_AccessionOrder.MasterAccessionNo); this.m_PageHeaderText = this.m_AccessionOrder.MasterAccessionNo + ": " + this.m_AccessionOrder.PFirstName + " " + this.m_AccessionOrder.PLastName; InitializeComponent(); DataContext = this; Loaded += new RoutedEventHandler(FixationDetailsPage_Loaded); }
public SpecimenOrderDetailsPage(YellowstonePathology.Business.Test.AccessionOrder accessionOrder, YellowstonePathology.Business.Specimen.Model.SpecimenOrder specimenOrder) { this.m_AccessionOrder = accessionOrder; this.m_SpecimenOrder = specimenOrder; this.m_ProcessorRunCollection = Business.Surgical.ProcessorRunCollection.GetAll(true); this.m_SpecimenCollection = YellowstonePathology.Business.Specimen.Model.SpecimenCollection.GetAll(); this.m_FixationTypeCollection = YellowstonePathology.Business.Specimen.Model.FixationType.GetFixationTypeCollection(); this.m_SpecimenAdequacyTypes = new FinalizeAccession.SpecimenAdequacyTypes(); InitializeComponent(); DataContext = this; this.Loaded += new RoutedEventHandler(SpecimenOrderDetailsPage_Loaded); Unloaded += SpecimenOrderDetailsPage_Unloaded; }
private void EmbeddingDialog_Loaded(object sender, RoutedEventArgs e) { this.Dispatcher.BeginInvoke(System.Windows.Threading.DispatcherPriority.Input, new System.Threading.ThreadStart(delegate() { this.m_BarcodeScanPort.HistologyBlockScanReceived += this.HistologyBlockScanReceived; this.m_BarcodeScanPort.ContainerScanReceived += BarcodeScanPort_ContainerScanReceived; this.m_AliquotOrderHoldCollection = YellowstonePathology.Business.Gateway.AccessionOrderGateway.GetAliquotOrderHoldCollection(); this.m_ProcessorRunCollection = YellowstonePathology.Business.Surgical.ProcessorRunCollection.GetAll(); this.m_EmbeddingNotScannedList = Business.Gateway.AccessionOrderGateway.GetEmbeddingNotScannedCollection(this.GetWorkingAccessionDate()); this.m_EmbeddingBreastCaseList = Business.Gateway.AccessionOrderGateway.GetEmbeddingBreastCasesCollection(); this.m_EmbeddingAutopsyList = Business.Gateway.AccessionOrderGateway.GetEmbeddingAutopsyUnverifiedList(); this.CalculateEstimatedFixationDuration(); this.NotifyPropertyChanged(string.Empty); } )); }
public UserPreferences() { this.m_MolecularLabelFormatCollection = YellowstonePathology.Business.Label.Model.LabelFormatCollection.GetMolecularLabelCollection(); this.m_UserPreference = YellowstonePathology.Business.User.UserPreferenceInstance.Instance.UserPreference; this.m_FacilityCollection = Business.Facility.Model.FacilityCollection.GetAllFacilities(); this.m_LocationCollection = new Business.Facility.Model.LocationCollection(); System.Printing.LocalPrintServer printServer = new System.Printing.LocalPrintServer(); this.m_PrintQueueCollection = printServer.GetPrintQueues(new[] { System.Printing.EnumeratedPrintQueueTypes.Local, System.Printing.EnumeratedPrintQueueTypes.Connections }); this.m_ApplicationVersion = YellowstonePathology.Business.Persistence.DocumentGateway.Instance.GetApplicationVersion(this); this.m_ProcessorRunCollection = Business.Surgical.ProcessorRunCollection.GetAll(true); InitializeComponent(); this.DataContext = this; this.Loaded += new RoutedEventHandler(UserPreferences_Loaded); this.Closing += UserPreferences_Closing; }
public ProcessorRun Get(YellowstonePathology.Business.User.UserPreference userPreference) { YellowstonePathology.Business.Surgical.ProcessorRunCollection processorRunCollection = YellowstonePathology.Business.Surgical.ProcessorRunCollection.GetAll(true); YellowstonePathology.Business.Surgical.ProcessorRun result = null; switch (DateTime.Today.DayOfWeek) { case DayOfWeek.Monday: case DayOfWeek.Tuesday: case DayOfWeek.Wednesday: case DayOfWeek.Thursday: result = processorRunCollection.Get(YellowstonePathology.Business.User.UserPreferenceInstance.Instance.UserPreference.WeekdayProcessorRunId); break; case DayOfWeek.Friday: case DayOfWeek.Saturday: case DayOfWeek.Sunday: result = processorRunCollection.Get(YellowstonePathology.Business.User.UserPreferenceInstance.Instance.UserPreference.WeekendProcessorRunId); break; } return(result); }
public FixationUpdate(YellowstonePathology.Business.Specimen.Model.SpecimenOrder specimenOrder, YellowstonePathology.Business.Surgical.ProcessorRunCollection processorRunCollection) { this.m_ClientAccessioned = specimenOrder.ClientAccessioned; this.m_TimeSpecimenCollected = specimenOrder.CollectionTime; this.m_DateSpecimenCollected = specimenOrder.CollectionDate; this.m_TimeSpecimenReceived = specimenOrder.DateReceived; this.m_ReceivedIn = specimenOrder.ClientFixation; //this.m_TimeToFixation = specimenOrder.TimeToFixation; //this.m_FixationDuration = specimenOrder.FixationDuration; this.m_SpecimenAccessioningAssumption = true; if (string.IsNullOrEmpty(specimenOrder.ProcessorRunId) == false) { this.m_ProcessorRun = processorRunCollection.Get(specimenOrder.ProcessorRunId); } }
private void EmbeddingDialog_Loaded(object sender, RoutedEventArgs e) { this.Dispatcher.BeginInvoke(System.Windows.Threading.DispatcherPriority.Input, new System.Threading.ThreadStart(delegate () { this.m_BarcodeScanPort.HistologyBlockScanReceived += this.HistologyBlockScanReceived; this.m_BarcodeScanPort.ContainerScanReceived += BarcodeScanPort_ContainerScanReceived; this.m_AliquotOrderHoldCollection = YellowstonePathology.Business.Gateway.AccessionOrderGateway.GetAliquotOrderHoldCollection(); this.m_ProcessorRunCollection = YellowstonePathology.Business.Surgical.ProcessorRunCollection.GetAll(); this.m_EmbeddingNotScannedList = Business.Gateway.AccessionOrderGateway.GetEmbeddingNotScannedCollection(this.GetWorkingAccessionDate()); this.m_EmbeddingBreastCaseList = Business.Gateway.AccessionOrderGateway.GetEmbeddingBreastCasesCollection(); this.NotifyPropertyChanged(string.Empty); } )); }
private void Bgw_DoWork(object sender, DoWorkEventArgs e) { YellowstonePathology.Business.Surgical.ProcessorRunCollection processorRunCollection = Business.Surgical.ProcessorRunCollection.GetAll(); foreach (YellowstonePathology.Business.BarcodeScanning.EmbeddingScan embeddingScan in this.ListViewEmbeddingScans.Items) { this.m_BackgroundWorker.ReportProgress(0, embeddingScan.AliquotOrderId); if (embeddingScan.Updated == false) { bool aliquotExists = YellowstonePathology.Business.Gateway.AccessionOrderGateway.DoesAliquotExist(embeddingScan.AliquotOrderId); if (aliquotExists == true) { YellowstonePathology.Business.Test.AliquotOrder aliquotOrder = YellowstonePathology.Business.Persistence.DocumentGateway.Instance.PullAliquotOrder(embeddingScan.AliquotOrderId, this); aliquotOrder.EmbeddingVerify(YellowstonePathology.Business.User.SystemIdentity.Instance.User); YellowstonePathology.Business.Facility.Model.Facility thisFacility = Business.Facility.Model.FacilityCollection.Instance.GetByFacilityId(YellowstonePathology.Business.User.UserPreferenceInstance.Instance.UserPreference.FacilityId); string thisLocation = YellowstonePathology.Business.User.UserPreferenceInstance.Instance.UserPreference.HostName; this.AddMaterialTrackingLog(aliquotOrder, thisFacility, thisLocation); aliquotOrder.SetLocation(thisFacility, thisLocation); Business.ParseSpecimenOrderIdResult parseSpecimenOrderIdResult = aliquotOrder.ParseSpecimenOrderIdFromBlock(); if (parseSpecimenOrderIdResult.ParsedSuccessfully == true) { YellowstonePathology.Business.Specimen.Model.SpecimenOrder specimenOrder = YellowstonePathology.Business.Persistence.DocumentGateway.Instance.PullSpecimenOrder(parseSpecimenOrderIdResult.SpecimenOrderId, this); if (specimenOrder.OkToSetProcessorTimes(embeddingScan.ProcessorStartTime) == true) { specimenOrder.ProcessorStartTime = embeddingScan.ProcessorStartTime; specimenOrder.ProcessorFixationTime = Convert.ToInt32(embeddingScan.ProcessorFixationDuration.Value.TotalMinutes); specimenOrder.SetFixationEndTime(); specimenOrder.SetFixationDuration(); } } else { MessageBox.Show("Unable to parse the Block Id. Please tell Sid."); } YellowstonePathology.Business.Persistence.DocumentGateway.Instance.Save(); this.m_AliquotOrderHoldCollection = YellowstonePathology.Business.Gateway.AccessionOrderGateway.GetAliquotOrderHoldCollection(); embeddingScan.Updated = true; this.m_EmbeddingScanCollection.UpdateStatus(embeddingScan); } else { this.m_AliquotsNotFoundList.Add(embeddingScan.AliquotOrderId); } } } if (this.m_AliquotsNotFoundList.Count > 0) { StringBuilder msg = new StringBuilder(); foreach (string id in this.m_AliquotsNotFoundList) { msg.AppendLine(id); } MessageBox.Show("The following Blocks were not found." + Environment.NewLine + msg.ToString()); this.m_AliquotsNotFoundList.Clear(); } }
private void ScanContainerPage_UseThisContainer(object sender, string containerId) { string masterAccessionNo = YellowstonePathology.Business.Gateway.AccessionOrderGateway.GetMasterAccessionNoFromContainerId(containerId); if (string.IsNullOrEmpty(masterAccessionNo) == false) { this.m_AccessionOrder = YellowstonePathology.Business.Persistence.DocumentGateway.Instance.PullAccessionOrder(masterAccessionNo, m_HistologyGrossDialog); if (this.m_AccessionOrder == null) { System.Windows.MessageBox.Show("The scanned container was not found."); this.ShowScanContainerPage(); } else { if (this.m_AccessionOrder.IsLockAquiredByMe == true) { YellowstonePathology.Business.Specimen.Model.SpecimenOrder specimenOrder = this.m_AccessionOrder.SpecimenOrderCollection.GetSpecimenOrderByContainerId(containerId); this.AddMaterialTrackingLog(specimenOrder); if (this.m_HistologyGrossDialog.PageNavigator.HasDualMonitors() == true) { DictationTemplatePage dictationTemplatePage = new DictationTemplatePage(specimenOrder, this.m_AccessionOrder, this.m_SystemIdentity); this.m_SecondaryWindow.PageNavigator.Navigate(dictationTemplatePage); } if (string.IsNullOrEmpty(specimenOrder.ProcessorRunId) == true) { YellowstonePathology.Business.Surgical.ProcessorRunCollection processorRunCollection = YellowstonePathology.Business.Surgical.ProcessorRunCollection.GetAll(false); YellowstonePathology.Business.Surgical.ProcessorRun processorRun = processorRunCollection.Get(YellowstonePathology.Business.User.UserPreferenceInstance.Instance.UserPreference); specimenOrder.SetProcessor(processorRun); specimenOrder.SetFixationDuration(); } if (this.m_AccessionOrder.PrintMateColumnNumber == 0 && this.m_AccessionOrder.PanelSetOrderCollection.HasTestBeenOrdered(48) == false) { this.ShowBlockColorSelectionPage(specimenOrder); } else { this.ShowPrintBlockPage(specimenOrder); } } else { this.ShowCaseLockPage(); } } } else { System.Windows.MessageBox.Show("The scanned container was not found."); this.ShowScanContainerPage(); } }