protected override bool Execute(RegistrationWorklistItemSummary item) { if (OrderCheckInHelper.CheckIn(item.OrderRef, PersonNameFormat.Format(item.PatientName), this.Context.DesktopWindow)) { this.Context.InvalidateFolders(typeof(Folders.Registration.CheckedInFolder)); return(true); } return(false); }
public void Reconcile() { if (this.ContextBase is IRegistrationWorkflowItemToolContext) { IRegistrationWorkflowItemToolContext context = (IRegistrationWorkflowItemToolContext)this.ContextBase; RegistrationWorklistItemSummary item = CollectionUtils.FirstElement <RegistrationWorklistItemSummary>(context.SelectedItems); if (ShowReconciliationDialog(item.PatientProfileRef, context.DesktopWindow)) { context.InvalidateSelectedFolder(); } } else { IPatientBiographyToolContext context = (IPatientBiographyToolContext)this.ContextBase; ShowReconciliationDialog(context.PatientProfileRef, context.DesktopWindow); } }
public void Apply() { if (this.ContextBase is IRegistrationWorkflowItemToolContext) { IRegistrationWorkflowItemToolContext context = (IRegistrationWorkflowItemToolContext)this.ContextBase; RegistrationWorklistItemSummary item = CollectionUtils.FirstElement(context.SelectedItems); if (Edit(item.PatientProfileRef, context.DesktopWindow)) { context.InvalidateSelectedFolder(); } } else if (this.ContextBase is IPatientSearchToolContext) { IPatientSearchToolContext context = (IPatientSearchToolContext)this.ContextBase; Edit(context.SelectedProfile.PatientProfileRef, context.DesktopWindow); } else if (this.ContextBase is IPatientBiographyToolContext) { IPatientBiographyToolContext context = (IPatientBiographyToolContext)this.ContextBase; Edit(context.PatientProfileRef, context.DesktopWindow); } }