-
Notifications
You must be signed in to change notification settings - Fork 8
/
patient.go
45 lines (38 loc) · 1.25 KB
/
patient.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
package ie
import (
"time"
"github.com/intervention-engine/fhir/models"
)
type PatientService interface {
Patient(id string) (*Patient, error)
Patients() ([]Patient, error)
PatientsByID(ids []string) ([]Patient, error)
}
type Patient struct {
ID string `json:"id"`
Address Address `json:"address"`
Age int `json:"age"`
Gender string `json:"gender"`
BirthDate *models.FHIRDateTime `json:"birthDate"`
Name Name `json:"name"`
NextHuddleID string `json:"nextHuddleId"`
RecentRiskAssessments []RiskAssessment `json:"recentRiskAssessments"`
}
type Address struct {
Street []string `json:"street"`
City string `json:"city"`
State string `json:"state"`
PostalCode string `json:"postalCode"`
}
type Name struct {
Family string `json:"family"`
Given string `json:"given"`
MiddleInitial string `json:"middleInitial"`
Full string `json:"full"`
}
type RiskAssessment struct {
ID string `json:"id"`
GroupID string `json:"riskAssessmentGroupId"`
Date time.Time `json:"date"`
Value int `json:"value"`
}