@pih/esm-pathology-app 1.0.5 → 1.1.1-pre.22

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (76) hide show
  1. package/.turbo/turbo-build.log +31 -0
  2. package/__mocks__/react-i18next.js +17 -16
  3. package/dist/39.js +2 -0
  4. package/dist/39.js.map +1 -0
  5. package/dist/574.js +1 -1
  6. package/dist/784.js +3 -0
  7. package/dist/{294.js.LICENSE.txt → 784.js.LICENSE.txt} +0 -0
  8. package/dist/784.js.map +1 -0
  9. package/dist/858.js +3 -0
  10. package/dist/858.js.LICENSE.txt +1 -0
  11. package/dist/858.js.map +1 -0
  12. package/dist/862.js +2 -0
  13. package/dist/862.js.map +1 -0
  14. package/dist/pih-esm-pathology-app.js +1 -2
  15. package/dist/pih-esm-pathology-app.js.buildmanifest.json +38 -98
  16. package/dist/pih-esm-pathology-app.js.map +1 -1
  17. package/dist/pih-esm-pathology-app.old +2 -0
  18. package/jest.config.json +2 -3
  19. package/package.json +10 -58
  20. package/src/Pathology-getter/Pathology-encounter-getter-resource.ts +15 -0
  21. package/src/Pathology-getter/Pathology-patient-encounters-getter-resource.ts +15 -0
  22. package/src/Pathology-getter/Pathology-patients-getter-resource.ts +12 -0
  23. package/src/config-schema.ts +22 -163
  24. package/src/declarations.d.tsx +1 -3
  25. package/src/pathology-report/ReportComponent.css +17 -39
  26. package/src/pathology-report/ReportComponent.tsx +38 -489
  27. package/src/pathology-report/TableRow.tsx +24 -0
  28. package/src/pathology.test.tsx +32 -0
  29. package/tsconfig.json +1 -19
  30. package/webpack.config.js +1 -30
  31. package/.babelrc +0 -10
  32. package/.eslintignore +0 -1
  33. package/.eslintrc +0 -5
  34. package/.gitattributes +0 -1
  35. package/.husky/pre-commit +0 -7
  36. package/.prettierignore +0 -2
  37. package/README.md +0 -4
  38. package/babel.config.json +0 -8
  39. package/dist/00ebb57bb20c59433e84.gif +0 -0
  40. package/dist/16.js +0 -3
  41. package/dist/16.js.LICENSE.txt +0 -1
  42. package/dist/16.js.map +0 -1
  43. package/dist/24.js +0 -3
  44. package/dist/24.js.LICENSE.txt +0 -16
  45. package/dist/24.js.map +0 -1
  46. package/dist/248.js +0 -3
  47. package/dist/248.js.LICENSE.txt +0 -99
  48. package/dist/248.js.map +0 -1
  49. package/dist/294.js +0 -3
  50. package/dist/294.js.map +0 -1
  51. package/dist/5b8bb278fcab4da4972e.ttf +0 -0
  52. package/dist/861.js +0 -2
  53. package/dist/861.js.map +0 -1
  54. package/dist/867.js +0 -2
  55. package/dist/867.js.map +0 -1
  56. package/dist/976.js +0 -3
  57. package/dist/976.js.LICENSE.txt +0 -8
  58. package/dist/976.js.map +0 -1
  59. package/dist/a5fad24f075c978ac04b.ttf +0 -0
  60. package/src/Fonts/georgia/GEORGIA4.TTF +0 -0
  61. package/src/Fonts/georgia/Georgia Bold Italic font.ttf +0 -0
  62. package/src/Fonts/georgia/Georgia Regular font.ttf +0 -0
  63. package/src/Fonts/georgia/Georgia.ttf +0 -0
  64. package/src/Fonts/georgia/georgia bold italic.ttf +0 -0
  65. package/src/Fonts/georgia/georgia italic.ttf +0 -0
  66. package/src/Fonts/georgia/georgia-bold.ttf +0 -0
  67. package/src/Fonts/georgia/georgiab.ttf +0 -0
  68. package/src/Fonts/georgia/georgiai.ttf +0 -0
  69. package/src/Fonts/georgia/georgiaz.ttf +0 -0
  70. package/src/Fonts/georgia/seriffic.ttf +0 -0
  71. package/src/Fonts/georgia/sharefonts.net.txt +0 -1
  72. package/src/Print-to-PDF/Document-Component.tsx +0 -256
  73. package/src/images/ButaroHospitalLogo.gif +0 -0
  74. package/src/pathology-report/ReportComponent.resource.ts +0 -279
  75. package/src/pathology-report/ReportComponent.test.tsx +0 -251
  76. package/src/test.html +0 -0
@@ -1,256 +0,0 @@
1
- import React from "react";
2
- import { Document, Page, Text,Image, View, StyleSheet,Font } from "@react-pdf/renderer";
3
- import ButaroLogo from '../images/ButaroHospitalLogo.gif';
4
- import GeorgiaFontBold from '../Fonts/georgia/georgia-bold.ttf';
5
- import GeorgiaFont from '../Fonts/georgia/Georgia.ttf';
6
-
7
- // import { Font } from '@react-pdf/renderer';
8
- Font.register({ family: 'GeorgiaBold', src: GeorgiaFontBold});
9
- Font.register({ family: 'Georgia', src: GeorgiaFont});
10
-
11
- // Font.register({ family: 'Georgia', src: '../Fonts/georgia/Georgia.ttf', fontStyle: 'normal', fontWeight: 'normal' });
12
-
13
-
14
-
15
-
16
- // Create styles
17
- const styles = StyleSheet.create({
18
- page: {
19
- flexDirection: "row",
20
- },
21
- section: {
22
- margin: 10,
23
- padding: 20,
24
- flexGrow: 1,
25
- },
26
- textLabels: {
27
- padding: 7,
28
- fontFamily:"GeorgiaBold",
29
- fontSize: 16,
30
- fontWeight: 'bold',
31
- paddingBottom:30,
32
- },
33
- sentenceLabels: {
34
- paddingTop: 7,
35
- fontFamily:"GeorgiaBold",
36
- fontSize: 16,
37
- fontWeight: 'bold',
38
- paddingBottom:3,
39
- },
40
- textAnswers: {
41
- margin: 10,
42
- padding: 20,
43
- fontFamily:"Georgia",
44
- fontSize: 14,
45
- },
46
- sentenceAnswers: {
47
- marginBottom: 10,
48
- paddingBottom: 20,
49
- fontFamily:"Georgia",
50
- fontSize: 14,
51
- },
52
- logo: {
53
- width: 61,
54
-
55
- }
56
- });
57
-
58
- // Create Document Component
59
- const MyDocument = (props) => (
60
-
61
- <Document title={`Pathology report
62
- ${props.encounterInfo.family_name}
63
- ${props.encounterInfo.given_name}
64
- ${props.encounterInfo.middle_name} `}
65
- >
66
- <Page size="A4" style={styles.page}>
67
-
68
- <View style={styles.section}>
69
- <Image style={styles.logo} src={ButaroLogo}/>
70
- <Text style={{fontSize: 8}}>Butaro Hospital</Text>
71
- <Text style={{ position: "absolute",top: 0,left: 300,width: 300 }}>
72
- <Text style={styles.textAnswers}>
73
- Lab phone number:
74
- </Text>
75
- <Text>{" "}{" "}0784433618</Text>
76
- </Text>
77
- <Text style={{ position: "absolute",top: 15,left: 300,width: 300 }}>
78
- <Text style={styles.textAnswers}>
79
- Accession number:
80
- </Text>
81
- <Text >
82
- {" "}{" "}
83
- {props.encounterInfo.resultsEncounter.obs.map((obser) => obser.concept.uuid==props.config.AccessionNumberconceptUUID && obser.value)}
84
- </Text>
85
- </Text>
86
- <Text style={{ backgroundColor: "#E4E4E4",borderBottom:'1px', textAlign: 'center',fontWeight: 1500, marginBottom: 30,fontFamily:"GeorgiaBold" }}>
87
- Pathology Report
88
- </Text>
89
- <Text style={{ paddingBottom: 10 }} >
90
- <Text style={styles.textAnswers}>
91
- Patient Name:
92
- </Text>
93
- <Text style={styles.textAnswers}>
94
- {" "}{" "}
95
- {props.encounterInfo.family_name} {" "}
96
- {props.encounterInfo.given_name} {" "}
97
- {props.encounterInfo.middle_name}
98
- </Text>
99
-
100
- </Text>
101
- <Text style={{ paddingBottom: 10, position: "absolute",top: 140,left: 335 }}>
102
- <Text style={styles.textAnswers}>
103
- Surgery Date:
104
- </Text>
105
- <Text style={styles.textAnswers}>
106
- {" "}{" "}
107
- {props.encounterInfo.resultsEncounter.obs.map((obser) => obser.concept.uuid==props.config.DateBiopsySpecimenTakenconceptUUID &&
108
- new Date(obser.value)
109
- .toLocaleString(["en-GB","en-US","en","fr-RW"],{day: 'numeric',month: 'numeric',year: 'numeric'})
110
- )}
111
- </Text>
112
-
113
- </Text>
114
- <Text style={{ paddingBottom: 10 }} >
115
- <Text style={styles.textAnswers}>
116
- Patient Birthday:
117
- </Text>
118
- <Text style={styles.textAnswers}>
119
- {" "}{" "}
120
- {
121
- new Date(props.encounterInfo.personBirthdate)
122
- .toLocaleString(["en-GB","en-US","en","fr-RW"],{day: 'numeric',month: 'numeric',year: 'numeric'})
123
- }
124
- </Text>
125
-
126
- </Text>
127
- <Text style={{ paddingBottom: 10, position: "absolute",top: 168,left: 335,width: 200 }}>
128
- <Text style={styles.textAnswers}>
129
- Specimen Reception Date:
130
- </Text>
131
- <Text style={styles.textAnswers}>
132
- {" "}{" "}
133
- {props.encounterInfo.resultsEncounter.obs.map((obser) => obser.concept.uuid==props.config.SpecimenSubmissionDateconceptUUID &&
134
- new Date(obser.value)
135
- .toLocaleString(["en-GB","en-US","en","fr-RW"],{day: 'numeric',month: 'numeric',year: 'numeric'})
136
- )}
137
- </Text>
138
- </Text>
139
- <Text style={{ paddingBottom: 10,borderBottom:'1px' }} >
140
- <Text style={styles.textAnswers}>
141
- Patient Gender:
142
- </Text>
143
- <Text style={styles.textAnswers}>
144
- {" "}{" "}
145
- {props.encounterInfo.personGender}
146
- </Text>
147
-
148
- </Text>
149
- <Text style={{ paddingBottom: 10, position: "absolute",top: 200,left: 335,width: 250 }}>
150
- <Text style={styles.textAnswers}>
151
- Signout Date:
152
- </Text>
153
- <Text style={styles.textAnswers}>
154
- {" "}{" "}
155
- {
156
- new Date(props.encounterInfo.resultsEncounter.encounterDatetime)
157
- .toLocaleString(["en-GB","en-US","en","fr-RW"],{day: 'numeric',month: 'numeric',year: 'numeric'})
158
- }
159
- </Text>
160
- </Text>
161
-
162
- <Text style={{ backgroundColor: "#E4E4E4",paddingBottom: 10 }}>
163
- <Text style={styles.textLabels}>
164
- Sending Physician:
165
- </Text>
166
- <Text style={styles.textAnswers}>
167
- {" "}{" "}
168
- {props.encounterInfo.resultsEncounter.obs.map((obser) => obser.concept.uuid==props.config.SendingPhysicianconceptUUID && obser.value)}
169
- </Text>
170
- </Text>
171
- <Text style={{ backgroundColor: "#E4E4E4",paddingBottom: 10 }}>
172
- <Text style={styles.textLabels}>
173
- Sending Facility:
174
- </Text>
175
- <Text style={styles.textAnswers}>
176
- {" "}{" "}
177
- {props.encounterInfo.resultsEncounter.obs.map((obser) => obser.concept.uuid==props.config.OtherBiopsyLocationconceptUUID && obser.value)}
178
- </Text>
179
- </Text>
180
- <Text style={{backgroundColor: "#E4E4E4",paddingBottom: 10 ,fontFamily:"Georgia"}}>Anatomical location:</Text>
181
- <Text style={{backgroundColor: "#E4E4E4", paddingBottom: 10,paddingLeft:10 }}>
182
- <Text style={styles.textLabels}>
183
- i.System:
184
- </Text>
185
- <Text style={styles.textAnswers}>
186
- {" "}{" "}
187
- {props.encounterInfo.resultsEncounter.obs.map((obser) => obser.concept.uuid==props.config.OrganSystemconceptUUID && (obser.value.name.display+ ", "))}
188
- </Text>
189
- </Text>
190
- <Text style={{backgroundColor: "#E4E4E4", paddingBottom: 10,paddingLeft:10 }}>
191
- <Text style={styles.textLabels}>
192
- ii.Organ:
193
- </Text>
194
- <Text style={styles.textAnswers}>
195
- {" "}{" "}
196
- {props.encounterInfo.resultsEncounter.obs.map((obser) => obser.concept.uuid==props.config.OrganconceptUUID && (obser.value.name.display+ ", "))}
197
- </Text>
198
- </Text>
199
- <Text style={{backgroundColor: "#E4E4E4", paddingBottom: 10,paddingLeft:10 }}>
200
- <Text style={styles.textLabels}>
201
- iii.Detail:
202
- </Text>
203
- <Text style={styles.textAnswers}>
204
- {" "}{" "}
205
- {props.encounterInfo.resultsEncounter.obs.map((obser) => obser.concept.uuid==props.config.SpecimenDetailconceptUUID && obser.value)}
206
- </Text>
207
- </Text>
208
- <Text style={{backgroundColor: "#E4E4E4", paddingBottom: 10 }}>
209
- <Text style={styles.textLabels}>
210
- Procedure type:
211
- </Text>
212
- <Text style={styles.textAnswers}>
213
- {" "}{" "}
214
- {props.encounterInfo.resultsEncounter.obs.map((obser) => obser.concept.uuid==props.config.OtherTestsOrProceduresconceptUUID && obser.value)}
215
- </Text>
216
- </Text>
217
- <Text style={[styles.sentenceLabels]}>
218
- Gross Description:
219
- </Text>
220
- <Text style={[styles.sentenceAnswers]}>
221
- {props.encounterInfo.resultsEncounter.obs.map((obser) => obser.concept.uuid==props.config.GrossDescriptionconceptUUID && obser.value)}
222
-
223
- </Text>
224
- <Text style={styles.sentenceLabels}>
225
- Microscopic Examination:
226
- </Text>
227
- <Text style={styles.sentenceAnswers}>
228
-
229
- {props.encounterInfo.resultsEncounter.obs.map((obser) => obser.concept.uuid==props.config.MacroscopicExaminationconceptUUID && obser.value)}
230
-
231
- </Text>
232
- <Text style={styles.sentenceLabels}>
233
- Conclusion:
234
- </Text>
235
- <Text style={styles.sentenceAnswers}>
236
-
237
- {props.encounterInfo.resultsEncounter.obs.map((obser) => obser.concept.uuid==props.config.COMMENTSATCONCLUSIONOFEXAMINATIONconceptUUID && obser.value)}
238
-
239
- </Text>
240
-
241
- <Text style={{backgroundColor: "#E4E4E4", paddingBottom: 10 }}>
242
- <Text style={styles.textLabels}>
243
- Validated by pathologist:
244
- </Text>
245
- <Text style= {[styles.textAnswers, { fontWeight: 'bold' }]}>
246
- {" "}{" "}
247
- {props.encounterInfo.approvedBy}
248
- </Text>
249
- </Text>
250
- </View>
251
- </Page>
252
- </Document>
253
- );
254
-
255
- export default MyDocument;
256
-
Binary file
@@ -1,279 +0,0 @@
1
- import { openmrsFetch } from "@openmrs/esm-framework";
2
- import cloneDeep from "lodash-es/cloneDeep";
3
-
4
-
5
- export interface EncounterResult {
6
- family_name: string;
7
- given_name: string;
8
- middle_name: string;
9
- patientPhoneNumber: { value: string };
10
- patientHealthCenter: string;
11
- patientUuid: string;
12
- encounterUuid: string;
13
- encounterId: number;
14
- personId: number;
15
- encounterDatetime: Date;
16
- sampleStatusObs: string;
17
- referralStatusObs: string;
18
- sampleDropoffObs: string;
19
- resultsEncounterId: string;
20
- resultsEncounterUuid: string;
21
- resultsEncounter: [];
22
- approvedBy: string;
23
- approvalObsUuid: string;
24
- pathologicDiagnosisObs: string;
25
- }
26
- export interface Patient {
27
- uuid: string;
28
- }
29
- export interface Concept {
30
- uuid: string;
31
- name: string;
32
- display: string;
33
- }
34
-
35
- export interface Obs {
36
- patientUuid: string;
37
- obsDateTime: string;
38
- sampleDropoffObsUuid: string;
39
- referralStatusObsUuid: string;
40
- sampleStatusObsUuid: string;
41
- location: string;
42
- encounterUuid: string;
43
- valueCodedName: string;
44
- voided: boolean;
45
- resultsEncounterUuid: string;
46
- }
47
-
48
-
49
- export async function getUserLocation(healthCenterAttrTypeUUID) {
50
- const session = await openmrsFetch(`/ws/rest/v1/session`);
51
- const personUuid = session.data.user.person.uuid;
52
- const person = await openmrsFetch(
53
- `/ws/rest/v1/person/${personUuid}/attribute`
54
- );
55
- const hcPersonAttribute = person.data.results.filter(
56
- (attr) => attr.attributeType.uuid === healthCenterAttrTypeUUID
57
- );
58
- return hcPersonAttribute[0] && hcPersonAttribute[0].value.uuid;
59
- }
60
-
61
- export async function getConceptAnswers(conceptUuid) {
62
- const concept = await openmrsFetch(
63
- `/ws/rest/v1/concept/${conceptUuid}?v=full`
64
- );
65
- return concept.data.answers;
66
- }
67
-
68
- export async function getLocations() {
69
- const location = await openmrsFetch(`/ws/rest/v1/location`);
70
-
71
- return location.data.results;
72
- }
73
-
74
- export async function getEncounters(
75
- healthCenterAttrTypeUUID: string,
76
- pathologyFullAllowedLocationUUID: string
77
- ): Promise<Array<EncounterResult>> {
78
- const userLocationUUID = await getUserLocation(healthCenterAttrTypeUUID);
79
-
80
- let searchEncounter = null;
81
- if (
82
- userLocationUUID &&
83
- userLocationUUID != pathologyFullAllowedLocationUUID
84
- ) {
85
- searchEncounter = await openmrsFetch(
86
- `/ws/rest/v1/reportingrest/reportdata/996cf192-ff54-11eb-a63a-080027ce9ca0?location=${userLocationUUID}`
87
- );
88
- } else {
89
- searchEncounter = await openmrsFetch(
90
- `/ws/rest/v1/reportingrest/reportdata/996cf192-ff54-11eb-a63a-080027ce9ca0`
91
- );
92
- }
93
-
94
- const EncListClone = searchEncounter.data.dataSets[0].rows.map(async (encObject)=>{
95
- if(encObject.resultsEncounterUuid){
96
- const encIndex = searchEncounter.data.dataSets[0].rows.findIndex(
97
- (enc) => enc.encounterUuid == encObject.encounterUuid
98
- );
99
- const resultsEnc =await getEncounter(encObject.resultsEncounterUuid);
100
- encObject.resultsEncounter = resultsEnc;
101
-
102
- }
103
- return encObject;
104
- });
105
-
106
- return Promise.all(EncListClone);
107
- }
108
-
109
- export async function postSampleDropoffObs(
110
- obsObject: Obs,
111
- sampleDropOffconceptUUID: string,
112
- healthCenterAttrTypeUUID: string,
113
- yesConceptName: string
114
- ) {
115
- const ObsObjectTocreate = {
116
- person: obsObject.patientUuid,
117
- obsDatetime: new Date().toISOString(),
118
- concept: sampleDropOffconceptUUID,
119
- location: await getUserLocation(healthCenterAttrTypeUUID),
120
- encounter: obsObject.encounterUuid,
121
- value: yesConceptName,
122
- voided: false,
123
- };
124
-
125
- const response = await openmrsFetch("/ws/rest/v1/obs", {
126
- method: "POST",
127
- headers: {
128
- "content-type": "application/json",
129
- },
130
- body: ObsObjectTocreate,
131
- });
132
- return response;
133
- }
134
-
135
- export async function voidSampleDropoff(sampleDropoffObsUuid: string) {
136
- const ObsObjectTocreate = {
137
- voided: true,
138
- };
139
-
140
- const response = await openmrsFetch(
141
- `/ws/rest/v1/obs/${sampleDropoffObsUuid}`,
142
- {
143
- method: "POST",
144
- headers: {
145
- "content-type": "application/json",
146
- },
147
- body: ObsObjectTocreate,
148
- }
149
- );
150
-
151
- return response;
152
- }
153
-
154
- export async function postSampleStatusChangeObs(
155
- newStatusUuid: string,
156
- obs: Obs,
157
- sampleStatusConceptUUID: string,
158
- healthCenterAttrTypeUUID: string
159
- ) {
160
- const postBody = {
161
- person: obs.patientUuid,
162
- obsDatetime: new Date().toISOString(),
163
- concept: sampleStatusConceptUUID,
164
- location: await getUserLocation(healthCenterAttrTypeUUID),
165
- encounter: obs.encounterUuid,
166
- value: newStatusUuid,
167
- voided: false,
168
- };
169
-
170
- const response = await openmrsFetch("/ws/rest/v1/obs", {
171
- method: "POST",
172
- headers: {
173
- "content-type": "application/json",
174
- },
175
- body: postBody,
176
- });
177
-
178
- return response;
179
- }
180
-
181
- export async function updateSampleStatusChangeObs(
182
- newStatus: null | { uuid: string; display: string },
183
- obsObject: Obs,
184
- sampleStatusConceptUUID: string,
185
- healthCenterAttrTypeUUID: string
186
- ) {
187
- const ObsObjectTocreate = {
188
- person: obsObject.patientUuid,
189
- obsDatetime: new Date().toISOString(),
190
- concept: sampleStatusConceptUUID,
191
- location: await getUserLocation(healthCenterAttrTypeUUID),
192
- encounter: obsObject.encounterUuid,
193
- value: newStatus.uuid,
194
- voided: newStatus ? false : true,
195
- };
196
-
197
- const response = await openmrsFetch(
198
- `/ws/rest/v1/obs/${obsObject.sampleStatusObsUuid}`,
199
- {
200
- method: "POST",
201
- headers: {
202
- "content-type": "application/json",
203
- },
204
- body: ObsObjectTocreate,
205
- }
206
- );
207
-
208
- return response;
209
- }
210
-
211
- export async function postReferralStatusChangeObs(
212
- targetValueUuid: string,
213
- obsObject: Obs,
214
- referralStatusConceptUUID: string,
215
- healthCenterAttrTypeUUID: string
216
- ) {
217
- const ObsObjectTocreate = {
218
- person: obsObject.patientUuid,
219
- obsDatetime: new Date().toISOString(),
220
- concept: referralStatusConceptUUID,
221
- location: await getUserLocation(healthCenterAttrTypeUUID),
222
- encounter: obsObject.encounterUuid,
223
- value: targetValueUuid,
224
- voided: false,
225
- };
226
-
227
- const response = await openmrsFetch("/ws/rest/v1/obs", {
228
- method: "POST",
229
- headers: {
230
- "content-type": "application/json",
231
- },
232
- body: ObsObjectTocreate,
233
- });
234
-
235
- return response;
236
- }
237
-
238
- export async function updateReferralStatusChangeObs(
239
- targetValue,
240
- obsObject: Obs,
241
- referralStatusConceptUUID,
242
- healthCenterAttrTypeUUID
243
- ) {
244
- const ObsObjectTocreate = {
245
- person: obsObject.patientUuid,
246
- obsDatetime: new Date().toISOString(),
247
- concept: referralStatusConceptUUID,
248
- location: await getUserLocation(healthCenterAttrTypeUUID),
249
- encounter: obsObject.encounterUuid,
250
- value: targetValue.uuid,
251
- voided: targetValue ? false : true,
252
- };
253
-
254
- const response = await openmrsFetch(
255
- `/ws/rest/v1/obs/${obsObject.referralStatusObsUuid}`,
256
- {
257
- method: "POST",
258
- headers: {
259
- "content-type": "application/json",
260
- },
261
- body: ObsObjectTocreate,
262
- }
263
- );
264
-
265
- return response;
266
- }
267
-
268
-
269
-
270
- export async function getUser(userUuid: string) {
271
- const user = await openmrsFetch(`/ws/rest/v1/user/${userUuid}`);
272
-
273
- return user.data;
274
- }
275
- export async function getEncounter(encounterUuid) {
276
- const encResult = await openmrsFetch(`/ws/rest/v1/encounter/${encounterUuid}?v=full`);
277
-
278
- return encResult.data;
279
- }