Last change
on this file since 1110 was 1110, checked in by Sam Habiel, 13 years ago |
CGDocument:
CGDocumentManager:
CGView: (Changes to support printing of Appointment Slip)
- Changed name and text of context menu to say "print appointment slip"
- Logic to Print Appointment Slip
CustomPrinting.cs renamed to Printing.cs; old Printing.Cs removed.
DAppointPage:
- New checkbox to request printing of Appointment Slip
- Sex of patient now pulled and included in form.
DPatientLetter:
- Redirected to use new Printing framework.
Patient:
Printing:
|
File size:
1.7 KB
|
Rev | Line | |
---|
[1107] | 1 | using System;
|
---|
| 2 | using System.Collections.Generic;
|
---|
| 3 | using System.Linq;
|
---|
| 4 | using System.Text;
|
---|
| 5 |
|
---|
| 6 | namespace IndianHealthService.ClinicalScheduling
|
---|
| 7 | {
|
---|
[1110] | 8 |
|
---|
[1107] | 9 | /// <summary>
|
---|
[1110] | 10 | /// You guessed it.
|
---|
| 11 | /// </summary>
|
---|
| 12 | public enum Sex
|
---|
| 13 | {
|
---|
| 14 | Male, Female
|
---|
| 15 | };
|
---|
| 16 |
|
---|
| 17 | /// <summary>
|
---|
[1107] | 18 | /// Puppet standing for a Real Patient
|
---|
| 19 | /// </summary>
|
---|
| 20 | public class Patient
|
---|
| 21 | {
|
---|
| 22 | public int DFN { get; set; }
|
---|
| 23 | public string Name { get; set; }
|
---|
[1110] | 24 | public Sex Sex;
|
---|
[1107] | 25 | public DateTime DOB { get; set; }
|
---|
| 26 | public string ID { get; set; }
|
---|
| 27 | public string HRN { get; set; }
|
---|
| 28 | public List<CGAppointment> Appointments { get; set; }
|
---|
| 29 | public string Street { get; set; }
|
---|
| 30 | public string City { get; set; }
|
---|
| 31 | public string State { get; set; }
|
---|
| 32 | public string Zip { get; set; }
|
---|
| 33 | public string Country { get; set; }
|
---|
| 34 | public string Email { get; set; }
|
---|
| 35 | public string HomePhone { get; set; }
|
---|
| 36 | public string WorkPHone { get; set; }
|
---|
| 37 | public string CellPhone { get; set; }
|
---|
[1110] | 38 | public TimeSpan Age
|
---|
| 39 | {
|
---|
| 40 | get
|
---|
| 41 | {
|
---|
| 42 | return (DateTime.Today - this.DOB);
|
---|
| 43 | }
|
---|
| 44 | }
|
---|
| 45 |
|
---|
| 46 | public string UserFriendlyAge
|
---|
| 47 | {
|
---|
| 48 | get
|
---|
| 49 | {
|
---|
| 50 | if (Age.TotalDays / 365.24 > 5)
|
---|
| 51 | return Math.Floor((Age.TotalDays / 365.24)).ToString() + " years";
|
---|
| 52 | else
|
---|
| 53 | return Math.Floor((Age.TotalDays / 365.24)).ToString() + " years & "
|
---|
| 54 | + Math.Floor(Age.TotalDays % 365.24 / 30).ToString() + " months";
|
---|
| 55 | }
|
---|
| 56 | }
|
---|
[1107] | 57 | }
|
---|
| 58 | }
|
---|
Note:
See
TracBrowser
for help on using the repository browser.