Exemple #1
0
        private void Open(IDesktopWindow desktopWindow)
        {
            try
            {
                var editor = new PatientProfileEditorComponent();
                var result = ApplicationComponent.LaunchAsDialog(
                    desktopWindow,
                    editor,
                    SR.TitleNewPatient);

                if (result == ApplicationComponentExitCode.Accepted && this.Context is IRegistrationWorkflowItemToolContext)
                {
                    // if patient successfully added, invoke a search on the MRN so that the patient appears in the Home page
                    var searchParams = new WorklistSearchParams(new WorklistItemTextQueryRequest.AdvancedSearchFields()
                    {
                        Mrn = editor.PatientProfile.Mrn.Id
                    });
                    ((IRegistrationWorkflowItemToolContext)this.Context).ExecuteSearch(searchParams);
                }
            }
            catch (Exception e)
            {
                ExceptionHandler.Report(e, desktopWindow);
            }
        }
Exemple #2
0
            protected override TextQueryResponse <ReportingWorklistItemSummary> DoQuery(WorklistSearchParams query, int specificityThreshold)
            {
                TextQueryResponse <ReportingWorklistItemSummary> response;

                WorklistItemTextQueryOptions options = WorklistItemTextQueryOptions.ProcedureStepStaff
                                                       | (DowntimeRecovery.InDowntimeRecoveryMode ? WorklistItemTextQueryOptions.DowntimeRecovery : 0);

                response = DoQueryCore(query, specificityThreshold, options, "ReportingProcedureStep");
                if (response.TooManyMatches)
                {
                    return(response);
                }

                List <ReportingWorklistItemSummary> storeMatches = new List <ReportingWorklistItemSummary>(response.Matches);

                response = DoQueryCore(query, specificityThreshold, options, "ProtocolAssignmentStep");

                if (!response.TooManyMatches)
                {
                    response.Matches.AddRange(storeMatches);
                }

                return(response);
            }