Ejemplo n.º 1
0
 /// <summary>
 /// Formats the MRN number according to the specified format string.
 /// </summary>
 /// <remarks>
 /// Valid format specifiers are as follows:
 ///     %N - number
 ///     %A - assigning authority
 /// </remarks>
 /// <param name="mrn"></param>
 /// <param name="format"></param>
 /// <returns></returns>
 public static string Format(CompositeIdentifierDetail mrn, string format)
 {
     string result = format;
     result = result.Replace("%N", mrn.Id ?? "");
     result = result.Replace("%A", mrn.AssigningAuthority == null ? "" : mrn.AssigningAuthority.Code);
     return result.Trim();
 }
Ejemplo n.º 2
0
 public VisitSummary(
     EntityRef visitRef,
     PatientProfileSummary patient,
     CompositeIdentifierDetail visitNumber,
     EnumValueInfo patientClass,
     EnumValueInfo patientType,
     EnumValueInfo admissionType,
     EnumValueInfo status,
     DateTime?admitTime,
     DateTime?dischargeTime,
     FacilitySummary facility,
     LocationSummary currentLocation,
     string currentRoom,
     string currentBed)
 {
     this.VisitRef        = visitRef;
     this.Patient         = patient;
     this.VisitNumber     = visitNumber;
     this.PatientClass    = patientClass;
     this.PatientType     = patientType;
     this.AdmissionType   = admissionType;
     this.Status          = status;
     this.AdmitTime       = admitTime;
     this.DischargeTime   = dischargeTime;
     this.Facility        = facility;
     this.CurrentLocation = currentLocation;
     this.CurrentRoom     = currentRoom;
     this.CurrentBed      = currentBed;
 }
Ejemplo n.º 3
0
		public PatientAuditData(CompositeIdentifierDetail mrn, PersonNameDetail name)
		{
			Mrn = string.Format("{0} {1}", mrn.AssigningAuthority.Code, mrn.Id);
			Name = string.IsNullOrEmpty(name.MiddleName) ? 
				string.Format("{0}, {1}", name.FamilyName, name.GivenName) 
				: string.Format("{0}, {1} {2}", name.FamilyName, name.GivenName, name.MiddleName);
		}
Ejemplo n.º 4
0
 public WorklistItemSummaryBase(
     EntityRef procedureStepRef,
     EntityRef procedureRef,
     EntityRef orderRef,
     EntityRef patientRef,
     EntityRef profileRef,
     CompositeIdentifierDetail mrn,
     PersonNameDetail name,
     string accessionNumber,
     EnumValueInfo orderPriority,
     EnumValueInfo patientClass,
     string diagnosticServiceName,
     string procedureName,
     bool procedurePortable,
     EnumValueInfo procedureLaterality,
     string procedureStepName,
     DateTime?time)
 {
     this.ProcedureStepRef  = procedureStepRef;
     this.ProcedureRef      = procedureRef;
     this.OrderRef          = orderRef;
     this.PatientRef        = patientRef;
     this.PatientProfileRef = profileRef;
     this.Mrn                   = mrn;
     this.PatientName           = name;
     this.AccessionNumber       = accessionNumber;
     this.OrderPriority         = orderPriority;
     this.PatientClass          = patientClass;
     this.DiagnosticServiceName = diagnosticServiceName;
     this.ProcedureName         = procedureName;
     this.ProcedurePortable     = procedurePortable;
     this.ProcedureLaterality   = procedureLaterality;
     this.ProcedureStepName     = procedureStepName;
     this.Time                  = time;
 }
Ejemplo n.º 5
0
		public OperationAuditData(string operation, CompositeIdentifierDetail mrn, PersonNameDetail name, string accessionNumber, string procedureName)
		{
			this.Operation = operation;
			this.Patient = new PatientAuditData(mrn, name);
			this.Order = new OrderAuditData(accessionNumber);
			this.Procedure = new ProcedureAuditData(procedureName);
		}
Ejemplo n.º 6
0
		public PatientBiographyDocument(PatientProfileSummary patientProfile, IDesktopWindow window)
			: base(patientProfile.PatientRef, window)
		{
			Platform.CheckForNullReference(patientProfile.PatientRef, "PatientRef");
			Platform.CheckForNullReference(patientProfile.PatientProfileRef, "PatientProfileRef");

			_patientRef = patientProfile.PatientRef;
			_profileRef = patientProfile.PatientProfileRef;
			_patientName = patientProfile.Name;
			_mrn = patientProfile.Mrn;
		}
Ejemplo n.º 7
0
		public PatientBiographyDocument(WorklistItemSummaryBase worklistItem, IDesktopWindow window)
			: base(worklistItem.PatientRef, window)
        {
			Platform.CheckForNullReference(worklistItem.PatientRef, "PatientRef");
			Platform.CheckForNullReference(worklistItem.PatientProfileRef, "PatientProfileRef");
			// the worklist item may not have an OrderRef (may represent just a patient)

			_patientRef = worklistItem.PatientRef;
			_profileRef = worklistItem.PatientProfileRef;
			_patientName = worklistItem.PatientName;
			_mrn = worklistItem.Mrn;

			_orderRef = worklistItem.OrderRef;
        }
Ejemplo n.º 8
0
 /// <summary>
 /// Formats the MRN according to the default format as specified in <see cref="FormatSettings"/>
 /// </summary>
 /// <param name="mrn"></param>
 /// <returns></returns>
 public static string Format(CompositeIdentifierDetail mrn)
 {
     return Format(mrn, FormatSettings.Default.MrnDefaultFormat);
 }
Ejemplo n.º 9
0
		public OperationAuditData(string operation, CompositeIdentifierDetail mrn, PersonNameDetail name)
		{
			this.Operation = operation;
			this.Patient = new PatientAuditData(mrn, name);
		}
Ejemplo n.º 10
0
		public OpenWorkspaceOperationAuditData(string workspace, CompositeIdentifierDetail mrn, PersonNameDetail name)
			: base(AuditHelper.Operations.DocumentWorkspaceOpen, mrn, name)
		{
			this.Workspace = workspace;
		}
Ejemplo n.º 11
0
		public PreviewOperationAuditData(string folderSystem, CompositeIdentifierDetail mrn, PersonNameDetail name, string accessionNumber)
			: base(AuditHelper.Operations.FolderItemPreview, mrn, name, accessionNumber)
		{
			this.FolderSystem = folderSystem;
		}
Ejemplo n.º 12
0
 /// <summary>
 /// Formats the MRN according to the default format as specified in <see cref="FormatSettings"/>
 /// </summary>
 /// <param name="vn"></param>
 /// <returns></returns>
 public static string Format(CompositeIdentifierDetail vn)
 {
     return Format(vn, FormatSettings.Default.VisitNumberDefaultFormat);
 }