Beispiel #1
0
 public TaggedNoteArray(string tag, Note note)
 {
     this.tag = tag;
     if (note == null)
     {
         this.count = 0;
         return;
     }
     this.notes = new NoteTO[1];
     this.notes[0] = new NoteTO(note);
     this.count = 1;
 }
Beispiel #2
0
 public TaggedNoteArray(string tag, Note[] notes)
 {
     this.tag = tag;
     if (notes == null)
     {
         this.count = 0;
         return;
     }
     this.notes = new NoteTO[notes.Length];
     for (int i = 0; i < notes.Length; i++)
     {
         this.notes[i] = new NoteTO(notes[i]);
     }
     this.count = notes.Length;
 }
Beispiel #3
0
 public NoteTO(Note mdoNote)
 {
     if (mdoNote == null) // || ((mdoNote.Id == null || mdoNote.Id == "") && mdoNote.ApprovedBy == null))
     {
         return;
     }
     this.id = mdoNote.Id;
     this.timestamp = mdoNote.Timestamp;
     this.admitTimestamp = mdoNote.AdmitTimestamp;
     this.dischargeTimestamp = mdoNote.DischargeTimestamp;
     this.localTitle = mdoNote.LocalTitle;
     this.standardTitle = mdoNote.StandardTitle;
     this.serviceCategory = mdoNote.ServiceCategory;
     if (mdoNote.Author != null)
     {
         this.author = new AuthorTO(mdoNote.Author);
     }
     if (mdoNote.Location != null)
     {
         this.location = new HospitalLocationTO(mdoNote.Location);
     }
     else if (!String.IsNullOrEmpty(mdoNote.SiteId.Id) || !String.IsNullOrEmpty(mdoNote.SiteId.Name))
     {
         HospitalLocation hl = new HospitalLocation(mdoNote.SiteId.Id, mdoNote.SiteId.Name);
         this.location = new HospitalLocationTO(hl);
     }
     this.text = mdoNote.Text;
     this.hasAddendum = mdoNote.HasAddendum;
     this.isAddendum = mdoNote.IsAddendum;
     this.originalNoteID = mdoNote.OriginalNoteId;
     this.hasImages = mdoNote.HasImages;
     if (mdoNote.ApprovedBy != null)
     {
         this.approvedBy = new AuthorTO(mdoNote.ApprovedBy);
     }
     this.status = mdoNote.Status;
 }