-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathconfig.js
More file actions
143 lines (137 loc) · 4.21 KB
/
config.js
File metadata and controls
143 lines (137 loc) · 4.21 KB
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
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
module.exports = {
// Application Port
port: 3000,
// Patient ID for Sample Data - Just needed for test
ptId: 12345,
// Valid Data Types
datatypes: ['allergies', 'medicians', 'problems'],
// Transformation Types
jsonata_maps: {
"TransformA-Allergy-UI2openEHR": `{
"allergies_and_adverse_reactions": {
"adverse_reaction_risk": {
"causative_agent": {
"value": cause,
"code": causeCode,
"terminology": causeTerminology
},
"reaction_details": {
"manifestation": {
"code": terminologyCode,
"value": reaction
}
}
}
},
"composer": {
"value": author
},
"start_time": $fromMillis(dateCreated),
"host": source,
"uid": sourceId,
"patientId": patientId
}`,
"TransformB-Allergy-UI2FHIR": `{
"resourceType": "AllergyIntolerance",
"identifier": [
{
"system": source,
"value": sourceId
}
],
"onset": $fromMillis(dateCreated),
"recordedDate": $fromMillis(dateCreated),
"recorder": {
"reference": "GMC Doctor",
"display": author
},
"patient": {
"reference": "=> fhirReference(patientId, 'Patient', false)",
"display": "{{patientName}}"
},
"substance": {
"coding": [
{
"system": causeCode,
"code": causeTerminology,
"display": cause
}
]
},
"status": "active",
"type": "allergy",
"category": "other",
"reaction": [
{
"substance": {
"coding": [
{
"system": causeCode,
"code": causeTerminology,
"display": cause
}
],
"text": cause
},
"certainty": "confirmed",
"manifestation": [
{
"coding": [
{
"system": terminologyCode,
"code": "TBC",
"display": reaction
}
],
"text": reaction
}
],
"description": reaction
}
],
"note": reaction
}`,
},
// Sample Data
sample_data: {
'allergies': {
"author": "Dr George Shannon",
"cause": "allergy to penicillin",
"causeCode": "SNOMED-CT",
"causeTerminology": 91936005,
"dateCreated": 1482178262000,
"originalComposition": "",
"originalSource": "",
"reaction": "eruption due to drug",
"source": "ethercis",
"sourceId": "74d1e386-5c2e-404c-bf65-29e3344285ef",
"terminologyCode": "SNOMED-CT"
},
'medicians': {
"author": "c4h_ripple_osi",
"dateCreated": 1446482102197,
"doseAmount": "1000mg",
"doseDirections": "Orally",
"doseTiming": "Orally Daily",
"medicationCode": "DefaultCode",
"medicationTerminology": "SNOMED-CT",
"name": "Amoxicillin",
"route": "RouteValue",
"source": "Marand",
"sourceId": "ba75d477-5ad4-4ad6-b126-94bd2324c101",
"startDate": 1448629200000,
"startTime": 46800000
},
'problems': {
"author": "Dr Tony Shannon",
"code": 299757012,
"dateCreated": 1445458262000,
"dateOfOnset": 963833437553,
"description": "",
"problem": "angina pectoris",
"source": "EtherCIS",
"sourceId": "12f02a05-a14f-4b35-be45-9e52bbe535ed",
"terminology": "SNOMED-CT"
}
}
};