@ampath/esm-reports-app 1.0.0-next.41 → 1.0.0-next.45
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.
- package/dist/143.css +1 -0
- package/dist/143.css.map +1 -0
- package/dist/143.js +1 -0
- package/dist/143.js.map +1 -0
- package/dist/197.js +1 -1
- package/dist/282.js +1 -1
- package/dist/282.js.map +1 -1
- package/dist/295.css +1 -0
- package/dist/295.css.map +1 -0
- package/dist/295.js +1 -0
- package/dist/295.js.map +1 -0
- package/dist/300.js +1 -1
- package/dist/311.js +1 -1
- package/dist/311.js.map +1 -1
- package/dist/335.js +1 -1
- package/dist/353.js +1 -1
- package/dist/353.js.map +1 -1
- package/dist/410.js +1 -0
- package/dist/410.js.map +1 -0
- package/dist/427.js +2 -0
- package/dist/427.js.LICENSE.txt +35 -0
- package/dist/427.js.map +1 -0
- package/dist/441.js +1 -0
- package/dist/441.js.map +1 -0
- package/dist/478.js +1 -1
- package/dist/478.js.map +1 -1
- package/dist/540.js +1 -1
- package/dist/540.js.map +1 -1
- package/dist/55.js +1 -1
- package/dist/652.js +1 -1
- package/dist/961.js +1 -1
- package/dist/961.js.map +1 -1
- package/dist/99.js +1 -1
- package/dist/ampath-esm-reports-app.js +1 -1
- package/dist/ampath-esm-reports-app.js.map +1 -1
- package/dist/routes.json +1 -1
- package/package.json +2 -2
- package/src/common/report-error/index.ts +1 -0
- package/src/common/report-error/show-report-error.ts +25 -0
- package/src/common/report-filters/date-range.ts +137 -0
- package/src/common/report-filters/index.ts +4 -0
- package/src/common/report-filters/report-filters.component.tsx +281 -151
- package/src/common/report-filters/report-filters.scss +180 -55
- package/src/common/report-filters/types.ts +66 -0
- package/src/common/report-filters/use-restore-period.ts +43 -0
- package/src/common/report-page/index.ts +2 -0
- package/src/common/report-page/report-page.component.tsx +32 -0
- package/src/common/report-page/report-page.scss +45 -0
- package/src/common/report-page/use-page-scale.ts +50 -0
- package/src/common/report-placeholder/has-report-data.ts +15 -0
- package/src/common/report-placeholder/index.ts +2 -0
- package/src/common/report-placeholder/report-placeholder.component.tsx +56 -0
- package/src/common/report-placeholder/report-placeholder.scss +46 -0
- package/src/common/report-register/index.ts +5 -0
- package/src/common/report-register/register-columns.ts +34 -0
- package/src/common/report-register/register-layout.component.tsx +237 -0
- package/src/common/report-register/register-layout.scss +140 -0
- package/src/common/report-register/register-table.scss +62 -0
- package/src/common/report-register/report-parents.ts +27 -0
- package/src/common/report-register/rows-to-csv.ts +59 -0
- package/src/common/report-register/use-patient-list.ts +92 -0
- package/src/common/report-skeleton/index.ts +1 -0
- package/src/common/report-skeleton/report-skeleton.component.tsx +46 -0
- package/src/common/report-skeleton/report-skeleton.scss +29 -0
- package/src/config-schema.ts +9 -1
- package/src/dashboard/report-catalog.ts +173 -0
- package/src/dashboard/reports-dasboard.tsx +101 -35
- package/src/dashboard/reports-dashboard.module.scss +269 -11
- package/src/index.ts +13 -1
- package/src/reports/datatable-wrapper/datatable-wrapper.component.tsx +50 -48
- package/src/reports/moh-240/moh-240-header.component.tsx +54 -56
- package/src/reports/moh-240/moh-240.columns.ts +64 -0
- package/src/reports/moh-240/moh-240.component.tsx +65 -84
- package/src/reports/moh-240/moh-240.scss +36 -7
- package/src/reports/moh-240/sub-reports/moh-240-register.component.tsx +27 -65
- package/src/reports/moh-240/sub-reports/page-summary.component.tsx +2 -2
- package/src/reports/moh-505/moh-505-header.component.tsx +59 -57
- package/src/reports/moh-505/moh-505.component.tsx +51 -56
- package/src/reports/moh-505/moh-505.scss +116 -2
- package/src/reports/moh-705B/moh-204b-register.component.tsx +41 -42
- package/src/reports/moh-705B/moh-204b.columns.ts +39 -0
- package/src/reports/moh-705B/moh-705b.component.tsx +492 -473
- package/src/reports/moh-705B/moh-705b.scss +110 -24
- package/src/reports/moh-705a/moh-705a.component.tsx +496 -476
- package/src/reports/moh-705a/moh-705a.scss +109 -24
- package/src/reports/moh-705a/registers/moh-204a-register.component.tsx +41 -42
- package/src/reports/moh-705a/registers/moh-204a.columns.ts +57 -0
- package/src/reports/moh-706/moh-706-header.component.tsx +58 -56
- package/src/reports/moh-706/moh-706.component.tsx +84 -55
- package/src/reports/moh-706/moh-706.scss +115 -19
- package/src/reports/moh-710/moh-710.component.tsx +743 -727
- package/src/reports/moh-710/moh-710.scss +140 -23
- package/src/reports/moh-710/registers/moh-511-710-register.component.tsx +48 -43
- package/src/reports/moh-710/registers/moh-511-710.columns.ts +52 -0
- package/src/reports/moh-711/moh-711.component.tsx +94 -106
- package/src/reports/moh-711/moh711.scss +95 -64
- package/src/reports/moh-711/registers/moh-333-register.component.tsx +92 -94
- package/src/reports/moh-711/registers/moh-333.columns.ts +119 -0
- package/src/reports/moh-711/registers/moh-405-register.component.tsx +88 -89
- package/src/reports/moh-711/registers/moh-405.columns.ts +120 -0
- package/src/reports/moh-711/registers/moh-406-register.component.tsx +85 -88
- package/src/reports/moh-711/registers/moh-406.columns.ts +133 -0
- package/src/reports/moh-711/registers/moh-510-register.component.tsx +38 -44
- package/src/reports/moh-711/registers/moh-511-register.component.tsx +42 -43
- package/src/reports/moh-711/registers/moh-511.columns.ts +59 -0
- package/src/reports/moh-711/sections/anc.component.tsx +3 -3
- package/src/reports/moh-711/sections/cervical-cancer.component.tsx +3 -3
- package/src/reports/moh-711/sections/chanis.component.tsx +2 -3
- package/src/reports/moh-711/sections/family-planning.component.tsx +2 -2
- package/src/reports/moh-711/sections/gbv.component.tsx +2 -2
- package/src/reports/moh-711/sections/maternity.component.tsx +3 -8
- package/src/reports/moh-711/sections/medical-social-work.component.tsx +2 -12
- package/src/reports/moh-711/sections/other.component.tsx +2 -2
- package/src/reports/moh-711/sections/physiotherapy.component.tsx +2 -2
- package/src/reports/moh-711/sections/pnc.component.tsx +7 -5
- package/src/reports/moh-711/sections/post-abortion.component.tsx +2 -2
- package/src/reports/moh-711/sections/rehabilitation.component.tsx +2 -2
- package/src/reports/moh-711/sections/report-compiled-by.component.tsx +12 -4
- package/src/reports/moh-711/sections/tb-screening.component.tsx +2 -2
- package/src/reports/moh-717/moh-717.component.tsx +100 -121
- package/src/reports/moh-717/moh717.scss +163 -102
- package/src/reports/moh-717/sections/maternity.component.tsx +1 -1
- package/src/reports/moh-717/sections/orthopaedic-trauma.component.tsx +1 -1
- package/src/reports/moh-717/sections/outpatient.component.tsx +23 -23
- package/src/reports/moh-717/sections/preparedby.component.tsx +7 -2
- package/src/reports/moh-717/sections/special-services.component.tsx +1 -1
- package/src/reports/moh-731/moh-731.component.tsx +127 -110
- package/src/reports/moh-731/moh-731.scss +396 -68
- package/src/reports/moh-731/registers/moh-366.columns.ts +38 -0
- package/src/reports/moh-731/registers/moh-366.component.tsx +76 -83
- package/src/reports/moh-731/registers/prep-register.component.tsx +70 -78
- package/src/reports/moh-731/registers/prep.columns.ts +34 -0
- package/src/reports/moh-731/sections/hiv-and-tb-treatment.component.tsx +1031 -751
- package/src/reports/moh-731/sections/hiv-testing-and-pre-exposure.component.tsx +230 -86
- package/src/reports/moh-731/sections/pmtct.component.tsx +185 -64
- package/src/reports/moh-740/moh-740.component.scss +159 -79
- package/src/reports/moh-740/moh-740.component.tsx +261 -230
- package/src/reports/moh-740/moh-740.resource.ts +17 -10
- package/src/reports/moh-740/registers/moh-222-daily-register/moh-222-daily-register.tsx +77 -96
- package/src/reports/moh-740/registers/moh-270-permanent-register/moh-270-permanent-register.tsx +50 -70
- package/src/reports/moh-740/registers/moh-740-patient-list.tsx +61 -32
- package/src/reports/moh-740/registers/moh-740.columns.ts +52 -0
- package/src/reports/moh-740/shared/utils/indicator-register-map.ts +3 -3
- package/src/reports/moh-740/types/index.ts +3 -3
- package/src/reports/moh-745/moh-745.component.tsx +897 -877
- package/src/reports/moh-745/moh-745.scss +104 -46
- package/src/reports/moh-745/registers/moh-412-register.component.tsx +42 -43
- package/src/reports/moh-745/registers/moh-412.columns.ts +52 -0
- package/src/reports/table-wrapper/table-wrapper.component.tsx +23 -14
- package/src/reports/table-wrapper/table-wrapper.scss +1 -16
- package/src/resources/moh-505.resource.ts +18 -35
- package/src/resources/moh-705.resource.ts +28 -39
- package/src/resources/moh-706.resource.ts +17 -30
- package/src/resources/moh-710.resource.ts +7 -17
- package/src/resources/moh-711.resource.ts +46 -64
- package/src/resources/moh-717.resource.ts +7 -17
- package/src/resources/moh-731.resource.ts +26 -32
- package/src/resources/moh-745.resource.ts +18 -20
- package/src/resources/patient-list-page.ts +66 -0
- package/src/root.component.tsx +28 -26
- package/src/root.scss +36 -0
- package/src/utils/get-base-url.ts +39 -7
- package/tsconfig.json +1 -1
- package/dist/110.js +0 -1
- package/dist/110.js.map +0 -1
- package/dist/184.js +0 -2
- package/dist/184.js.LICENSE.txt +0 -14
- package/dist/184.js.map +0 -1
- package/dist/205.js +0 -1
- package/dist/205.js.map +0 -1
- package/dist/812.js +0 -1
- package/dist/812.js.map +0 -1
- package/dist/822.js +0 -2
- package/dist/822.js.LICENSE.txt +0 -20
- package/dist/822.js.map +0 -1
- package/dist/ampath-esm-reports-app.js.buildmanifest.json +0 -560
- package/dist/main.js +0 -1
- package/dist/main.js.map +0 -1
- package/src/reports/moh-731/registers/moh-366.scss +0 -45
- package/src/reports/moh-731/registers/prep-registers.scss +0 -45
- package/src/reports/moh-740/registers/moh-222-daily-register/moh-222-daily-register.scss +0 -18
- package/src/reports/moh-740/registers/moh-270-permanent-register/moh-270-permanent-register.scss +0 -18
- /package/src/{reports/moh-740/shared/utils → utils}/format-indicator.ts +0 -0
|
@@ -1,17 +1,15 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import React
|
|
1
|
+
import { TableCell, TableRow } from '@carbon/react';
|
|
2
|
+
import React from 'react';
|
|
3
3
|
import { useLocation, useNavigate, useSearchParams } from 'react-router-dom';
|
|
4
4
|
|
|
5
|
-
import styles from '
|
|
5
|
+
import styles from '../../../common/report-register/register-table.scss';
|
|
6
6
|
import classNames from 'classnames';
|
|
7
7
|
import { getMoh405PatientList } from '../../../resources/moh-711.resource';
|
|
8
8
|
import { moh405Columns } from './type';
|
|
9
|
+
import { moh405ExportColumns } from './moh-405.columns';
|
|
10
|
+
import { RegisterLayout, usePatientList } from '../../../common/report-register';
|
|
9
11
|
|
|
10
12
|
const Moh405Register: React.FC = () => {
|
|
11
|
-
const navigate = useNavigate();
|
|
12
|
-
const [patientlist, setPatientList] = useState<any[]>([]);
|
|
13
|
-
const [isLoading, setIsLoading] = useState(false);
|
|
14
|
-
|
|
15
13
|
const [searchParams] = useSearchParams();
|
|
16
14
|
const location = useLocation();
|
|
17
15
|
|
|
@@ -21,42 +19,43 @@ const Moh405Register: React.FC = () => {
|
|
|
21
19
|
const indicator = searchParams.get('indicator');
|
|
22
20
|
const reportName = location.state?.reportName || '';
|
|
23
21
|
|
|
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
|
-
fetchData();
|
|
50
|
-
}, [startDate, endDate, locationUuids, indicator, reportName]);
|
|
51
|
-
function navigateBack() {
|
|
52
|
-
navigate('/moh-711');
|
|
53
|
-
}
|
|
22
|
+
const {
|
|
23
|
+
rows: patientlist,
|
|
24
|
+
total,
|
|
25
|
+
isTotalExact,
|
|
26
|
+
isLoading,
|
|
27
|
+
page,
|
|
28
|
+
pageSize,
|
|
29
|
+
onPageChange,
|
|
30
|
+
fetchAll,
|
|
31
|
+
} = usePatientList(
|
|
32
|
+
({ startIndex, limit }) =>
|
|
33
|
+
getMoh405PatientList({
|
|
34
|
+
startDate,
|
|
35
|
+
endDate,
|
|
36
|
+
locationUuids,
|
|
37
|
+
indicator,
|
|
38
|
+
reportName,
|
|
39
|
+
startIndex,
|
|
40
|
+
limit,
|
|
41
|
+
}),
|
|
42
|
+
[startDate, endDate, locationUuids, indicator, reportName],
|
|
43
|
+
);
|
|
54
44
|
return (
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
45
|
+
<RegisterLayout
|
|
46
|
+
parentLabel="MOH-711 Report"
|
|
47
|
+
parentPath="/moh-711"
|
|
48
|
+
title="MOH 405 ANC Register"
|
|
49
|
+
isLoading={isLoading}
|
|
50
|
+
isEmpty={patientlist.length === 0}
|
|
51
|
+
page={page}
|
|
52
|
+
pageSize={pageSize}
|
|
53
|
+
total={total}
|
|
54
|
+
isTotalExact={isTotalExact}
|
|
55
|
+
onPageChange={onPageChange}
|
|
56
|
+
fetchAll={fetchAll}
|
|
57
|
+
columns={moh405ExportColumns}
|
|
58
|
+
>
|
|
60
59
|
<div className={styles.tableContainer}>
|
|
61
60
|
<table className={classNames(`${styles.table}`, `${styles.tableBordered}`, `${styles.tableStriped}`)}>
|
|
62
61
|
<thead>
|
|
@@ -351,52 +350,52 @@ const Moh405Register: React.FC = () => {
|
|
|
351
350
|
</thead>
|
|
352
351
|
<tbody>
|
|
353
352
|
<tr>
|
|
354
|
-
<td className={styles.
|
|
355
|
-
<td className={styles.
|
|
356
|
-
<td className={styles.
|
|
357
|
-
<td className={styles.
|
|
358
|
-
<td className={styles.
|
|
359
|
-
<td className={styles.
|
|
360
|
-
<td className={styles.
|
|
361
|
-
<td className={styles.
|
|
362
|
-
<td className={styles.
|
|
363
|
-
<td className={styles.
|
|
364
|
-
<td className={styles.
|
|
365
|
-
<td className={styles.
|
|
366
|
-
<td className={styles.
|
|
367
|
-
<td className={styles.
|
|
368
|
-
<td className={styles.
|
|
369
|
-
<td className={styles.
|
|
370
|
-
<td className={styles.
|
|
371
|
-
<td className={styles.
|
|
372
|
-
<td className={styles.
|
|
373
|
-
<td className={styles.
|
|
374
|
-
<td className={styles.
|
|
375
|
-
<td className={styles.
|
|
376
|
-
<td className={styles.
|
|
377
|
-
<td className={styles.
|
|
378
|
-
<td className={styles.
|
|
379
|
-
<td className={styles.
|
|
380
|
-
<td className={styles.
|
|
381
|
-
<td className={styles.
|
|
382
|
-
<td className={styles.
|
|
383
|
-
<td className={styles.
|
|
384
|
-
<td className={styles.
|
|
385
|
-
<td className={styles.
|
|
386
|
-
<td className={styles.
|
|
387
|
-
<td className={styles.
|
|
388
|
-
<td className={styles.
|
|
389
|
-
<td className={styles.
|
|
390
|
-
<td className={styles.
|
|
391
|
-
<td className={styles.
|
|
392
|
-
<td className={styles.
|
|
393
|
-
<td className={styles.
|
|
394
|
-
<td className={styles.
|
|
395
|
-
<td className={styles.
|
|
396
|
-
<td className={styles.
|
|
397
|
-
<td className={styles.
|
|
398
|
-
<td className={styles.
|
|
399
|
-
<td className={styles.
|
|
353
|
+
<td className={styles.textCentre}>(a)</td>
|
|
354
|
+
<td className={styles.textCentre}>(b)</td>
|
|
355
|
+
<td className={styles.textCentre}>(c)</td>
|
|
356
|
+
<td className={styles.textCentre}>(d)</td>
|
|
357
|
+
<td className={styles.textCentre}>(e)</td>
|
|
358
|
+
<td className={styles.textCentre}>(f)</td>
|
|
359
|
+
<td className={styles.textCentre}>(g)</td>
|
|
360
|
+
<td className={styles.textCentre}>(h)</td>
|
|
361
|
+
<td className={styles.textCentre}>(i)</td>
|
|
362
|
+
<td className={styles.textCentre}>(j)</td>
|
|
363
|
+
<td className={styles.textCentre}>(k)</td>
|
|
364
|
+
<td className={styles.textCentre}>(l)</td>
|
|
365
|
+
<td className={styles.textCentre}>(m)</td>
|
|
366
|
+
<td className={styles.textCentre}>(n)</td>
|
|
367
|
+
<td className={styles.textCentre}>(o)</td>
|
|
368
|
+
<td className={styles.textCentre}>(p)</td>
|
|
369
|
+
<td className={styles.textCentre}>(q)</td>
|
|
370
|
+
<td className={styles.textCentre}>(r)</td>
|
|
371
|
+
<td className={styles.textCentre}>(s)</td>
|
|
372
|
+
<td className={styles.textCentre}>(t)</td>
|
|
373
|
+
<td className={styles.textCentre}>(u)</td>
|
|
374
|
+
<td className={styles.textCentre}>(v)</td>
|
|
375
|
+
<td className={styles.textCentre}>(w)</td>
|
|
376
|
+
<td className={styles.textCentre}>(x)</td>
|
|
377
|
+
<td className={styles.textCentre}>(y)</td>
|
|
378
|
+
<td className={styles.textCentre}>(z)</td>
|
|
379
|
+
<td className={styles.textCentre}>(aa)</td>
|
|
380
|
+
<td className={styles.textCentre}>(ab)</td>
|
|
381
|
+
<td className={styles.textCentre}>(ac)</td>
|
|
382
|
+
<td className={styles.textCentre}>(ad)</td>
|
|
383
|
+
<td className={styles.textCentre}>(ae)</td>
|
|
384
|
+
<td className={styles.textCentre}>(af)</td>
|
|
385
|
+
<td className={styles.textCentre}>(ag)</td>
|
|
386
|
+
<td className={styles.textCentre}>(ah)</td>
|
|
387
|
+
<td className={styles.textCentre}>(ai)</td>
|
|
388
|
+
<td className={styles.textCentre}>(aj)</td>
|
|
389
|
+
<td className={styles.textCentre}>(ak)</td>
|
|
390
|
+
<td className={styles.textCentre}>(al)</td>
|
|
391
|
+
<td className={styles.textCentre}>(am)</td>
|
|
392
|
+
<td className={styles.textCentre}>(an)</td>
|
|
393
|
+
<td className={styles.textCentre}>(ao)</td>
|
|
394
|
+
<td className={styles.textCentre}>(ap)</td>
|
|
395
|
+
<td className={styles.textCentre}>(aq)</td>
|
|
396
|
+
<td className={styles.textCentre}>(ar)</td>
|
|
397
|
+
<td className={styles.textCentre}>(as)</td>
|
|
398
|
+
<td className={styles.textCentre}>(at)</td>
|
|
400
399
|
</tr>
|
|
401
400
|
{patientlist?.length > 0 ? (
|
|
402
401
|
patientlist.map((patient, rowIndex) => (
|
|
@@ -514,7 +513,7 @@ const Moh405Register: React.FC = () => {
|
|
|
514
513
|
</tbody>
|
|
515
514
|
</table>
|
|
516
515
|
</div>
|
|
517
|
-
|
|
516
|
+
</RegisterLayout>
|
|
518
517
|
);
|
|
519
518
|
};
|
|
520
519
|
|
|
@@ -0,0 +1,120 @@
|
|
|
1
|
+
import { type RegisterColumn } from '../../../common/report-register';
|
|
2
|
+
|
|
3
|
+
/**
|
|
4
|
+
* MOH 405 as the register prints it: one column per cell, in the order they appear.
|
|
5
|
+
*
|
|
6
|
+
* The last 10 columns are rendered by the table but have no headings above
|
|
7
|
+
* them -- the header row is 46 columns wide against 56 of data. They carry
|
|
8
|
+
* their field names rather than headings borrowed from neighbouring columns.
|
|
9
|
+
*/
|
|
10
|
+
export const moh405ExportColumns: RegisterColumn[] = [
|
|
11
|
+
{ header: 'Date of visit', value: (row) => row.date_of_visit ?? '' },
|
|
12
|
+
{ header: '(New Client) - ANC Number - NUPI', value: (row) => row.anc_number ?? '' },
|
|
13
|
+
{ header: 'ANC Number/NUPI (Re Visit)', value: (row) => row.anc_number_NUPI ?? '' },
|
|
14
|
+
{ header: 'AMRSID', value: (row) => row.amrsID ?? '' },
|
|
15
|
+
{ header: 'Number of Visits (1st,2nd,3rd, 4th ….)', value: (row) => row.number_of_anc_visits ?? '' },
|
|
16
|
+
{ header: 'Full Name (First, Middle, Surname)', value: (row) => row.full_names ?? '' },
|
|
17
|
+
{ header: 'Date of Birth (DD/MM/YYYY) - Age', value: (row) => row.date_of_birth ?? '' },
|
|
18
|
+
{ header: 'Subcounty/ County', value: (row) => row.subcounty_county ?? '' },
|
|
19
|
+
{ header: 'Village/Estate/ Landmark - Phone Number', value: (row) => row.village_estate_landmark ?? '' },
|
|
20
|
+
{
|
|
21
|
+
header:
|
|
22
|
+
'Marital Status NM=Never Married/Single MM=Married Monogamous MP=Married Polygamous W=Widowed D=Divorced S=Separated',
|
|
23
|
+
value: (row) => row.marital_status ?? '',
|
|
24
|
+
},
|
|
25
|
+
{ header: 'Parity', value: (row) => row.parity ?? '' },
|
|
26
|
+
{ header: 'Gravidae', value: (row) => row.gravidae ?? '' },
|
|
27
|
+
{ header: 'Date of Last Menstrual Period (LMP) - (dd/mm/yyyy)', value: (row) => row.last_lmp_date ?? '' },
|
|
28
|
+
{ header: 'Expected Date of Delivery (EDD) - (dd/mm/yyyy)', value: (row) => row.edd ?? '' },
|
|
29
|
+
{ header: 'Gestation in Weeks', value: (row) => row.gestation_in_weeks ?? '' },
|
|
30
|
+
{ header: 'MUAC 1= Green, 2=Yellow, 3=Red', value: (row) => row.muac ?? '' },
|
|
31
|
+
{ header: 'Height (cm)', value: (row) => row.height ?? '' },
|
|
32
|
+
{ header: 'Weight (kg)', value: (row) => row.weight ?? '' },
|
|
33
|
+
{ header: 'Blood Pressure', value: (row) => row.blood_pressure ?? '' },
|
|
34
|
+
{ header: 'Breast Exam 1=normal 2=abnormal', value: (row) => row.breast_exam ?? '' },
|
|
35
|
+
{
|
|
36
|
+
header: 'FGM (Y/N) - FGM associated complications: 1=Scarring 2=Keloids 3=Dyspaneuria 4=UTI 5 = NA',
|
|
37
|
+
value: (row) => row.fgm ?? '',
|
|
38
|
+
},
|
|
39
|
+
{ header: 'Laboratory - Haemoglobin (Level/ ND/NA)', value: (row) => row.haemoglobin ?? '' },
|
|
40
|
+
{
|
|
41
|
+
header:
|
|
42
|
+
'Laboratory - Blood Sugar Testing for Diabetes: 1=RBS< 11.1 mmol/L, No Diabetes, 2=RBS>11.1 mmol/L, Has Diabetes, 3=No RBS done',
|
|
43
|
+
value: (row) => row.blood_sugar_test ?? '',
|
|
44
|
+
},
|
|
45
|
+
{ header: 'Laboratory - Blood group and rhesus (Y/N)', value: (row) => row.blood_group_rhesus ?? '' },
|
|
46
|
+
{ header: 'Laboratory - Urinalysis (Y/N)', value: (row) => row.urinalysis ?? '' },
|
|
47
|
+
{
|
|
48
|
+
header: 'Laboratory - Type of Test RPR/ VDRL/ Duo Test/ NA - Test Results (P/N/NA)',
|
|
49
|
+
value: (row) => row.rpr_vdrl_duo ?? '',
|
|
50
|
+
},
|
|
51
|
+
{
|
|
52
|
+
header: 'Laboratory - Hepatitis B virus Sceening Result (P/N/ND) - Treatment (Y/N/NA)',
|
|
53
|
+
value: (row) => row.hepatitisB ?? '',
|
|
54
|
+
},
|
|
55
|
+
{
|
|
56
|
+
header: 'Laboratory - TB Screening: Codes (1-5) - 1=Presumed TB 2=No Signs 3=On TB Treatment 4=On TPT 5=Not Done',
|
|
57
|
+
value: (row) => row.tb_screening ?? '',
|
|
58
|
+
},
|
|
59
|
+
{
|
|
60
|
+
header: 'Laboratory - HIV Testing (Initial or Retest, Known Poitive or Revisit) - (I/R/KP/ND/Rev)',
|
|
61
|
+
value: (row) => row.hiv_test_type ?? '',
|
|
62
|
+
},
|
|
63
|
+
{
|
|
64
|
+
header: 'Laboratory - HIV Test 1 - Kit Name - Expiry / / - (N/P/I/NA)',
|
|
65
|
+
value: (row) => row.hiv_test_1_kit_name ?? '',
|
|
66
|
+
},
|
|
67
|
+
{
|
|
68
|
+
header: 'Laboratory - HIV Test 2 - Kit Name - Expiry / / - (N/P/I/NA)',
|
|
69
|
+
value: (row) => row.hiv_test_2_kit_name ?? '',
|
|
70
|
+
},
|
|
71
|
+
{
|
|
72
|
+
header: 'Laboratory - HIV Test 3 - Kit Name - Expiry / / - (N/P/I/NA)',
|
|
73
|
+
value: (row) => row.hiv_test_3_kit_name ?? '',
|
|
74
|
+
},
|
|
75
|
+
{ header: 'Laboratory - HIV Results - (N/P/Ic/U/N A)', value: (row) => row.hiv_results ?? '' },
|
|
76
|
+
{
|
|
77
|
+
header: 'Maternal HAART - N = New on ART. OA = On ART NA = Not Applicable',
|
|
78
|
+
value: (row) => row.maternal_haart ?? '',
|
|
79
|
+
},
|
|
80
|
+
{ header: 'Infant Prophylaxis - AN = AZT&NVP A = AZT N = NVP NA', value: (row) => row.infant_prophylaxis ?? '' },
|
|
81
|
+
{ header: 'Partner HIV Testing - N/P/KP/NA', value: (row) => row.partner_hiv_testing ?? '' },
|
|
82
|
+
{
|
|
83
|
+
header:
|
|
84
|
+
'Other Conditions and Treatment - 1=Hypertension; 2=Diabetes; 3=Epilepsy; 4=Malaria in Pregnancy; 5=STIs/RTI; 6=Others (Specify) 7=None Record all that apply - Treatment (Y/N/NA)',
|
|
85
|
+
value: (row) => row.other_conditions ?? '',
|
|
86
|
+
},
|
|
87
|
+
{ header: 'Deworming - (Y/N/NA)', value: (row) => row.deworming ?? '' },
|
|
88
|
+
{ header: 'IPT 1-3 - (1,2,3,N,NA)', value: (row) => row.ipt_1_3 ?? '' },
|
|
89
|
+
{
|
|
90
|
+
header: 'TT Dose - 1=TT Dose 1st dose 2=2nd dose 3=3rd dose 4=4th dose 5=5th dose NA=None',
|
|
91
|
+
value: (row) => row.tt_dose ?? '',
|
|
92
|
+
},
|
|
93
|
+
{
|
|
94
|
+
header:
|
|
95
|
+
'Supplementation - Given Supplementation 1=Combined IFAs 2=Iron 3=Folate 4=Iron+Folate Separately 5=Calcium',
|
|
96
|
+
value: (row) => row.supplementation ?? '',
|
|
97
|
+
},
|
|
98
|
+
{ header: 'LLITNs - Received LLITNs (Y/N)', value: (row) => row.llitns ?? '' },
|
|
99
|
+
{
|
|
100
|
+
header: 'Referrrals - From - 1=From Community Unit 2=Another Health Facility 3=Not Applicable',
|
|
101
|
+
value: (row) => row.referrals_from ?? '',
|
|
102
|
+
},
|
|
103
|
+
{
|
|
104
|
+
header:
|
|
105
|
+
'Referrrals - To - 1=To Community Unit 2=HIV preventive services 3=Another Health Facility 4=Not Applicable',
|
|
106
|
+
value: (row) => row.referrals_to ?? '',
|
|
107
|
+
},
|
|
108
|
+
{ header: 'Referrrals - Reason for referral (specify)', value: (row) => row.reason_for_referral ?? '' },
|
|
109
|
+
{ header: 'Remarks', value: (row) => row.remarks ?? '' },
|
|
110
|
+
{ header: 'NUPI', value: (row) => row.NUPI ?? '' },
|
|
111
|
+
{ header: 'Age', value: (row) => row.age ?? '' },
|
|
112
|
+
{ header: 'Phone number', value: (row) => row.phone_number ?? '' },
|
|
113
|
+
{ header: 'Fgm complications', value: (row) => row.fgm_complications ?? '' },
|
|
114
|
+
{ header: 'Rpr vdrl duo results', value: (row) => row.rpr_vdrl_duo_results ?? '' },
|
|
115
|
+
{ header: 'Hepatitis B treatment', value: (row) => row.hepatitisB_treatment ?? '' },
|
|
116
|
+
{ header: 'Hiv test 1 expiry date', value: (row) => row.hiv_test_1_expiry_date ?? '' },
|
|
117
|
+
{ header: 'Hiv test 2 expiry date', value: (row) => row.hiv_test_2_expiry_date ?? '' },
|
|
118
|
+
{ header: 'Hiv test 3 expiry date', value: (row) => row.hiv_test_3_expiry_date ?? '' },
|
|
119
|
+
{ header: 'Other conditions treatment', value: (row) => row.other_conditions_treatment ?? '' },
|
|
120
|
+
];
|
|
@@ -1,18 +1,14 @@
|
|
|
1
|
-
import
|
|
2
|
-
import React, { useEffect, useState } from 'react';
|
|
1
|
+
import React from 'react';
|
|
3
2
|
import { useLocation, useNavigate, useSearchParams } from 'react-router-dom';
|
|
4
3
|
|
|
5
|
-
import styles from '
|
|
4
|
+
import styles from '../../../common/report-register/register-table.scss';
|
|
6
5
|
import classNames from 'classnames';
|
|
7
6
|
import { getMoh406PatientList } from '../../../resources/moh-711.resource';
|
|
8
7
|
import { moh406Columns } from './type';
|
|
8
|
+
import { moh406ExportColumns } from './moh-406.columns';
|
|
9
|
+
import { RegisterLayout, usePatientList } from '../../../common/report-register';
|
|
9
10
|
|
|
10
11
|
const Moh406Register: React.FC = () => {
|
|
11
|
-
const navigate = useNavigate();
|
|
12
|
-
|
|
13
|
-
const [patientlist, setPatientList] = useState<any[]>([]);
|
|
14
|
-
const [isLoading, setIsLoading] = useState(false);
|
|
15
|
-
|
|
16
12
|
const [searchParams] = useSearchParams();
|
|
17
13
|
const location = useLocation();
|
|
18
14
|
|
|
@@ -22,42 +18,43 @@ const Moh406Register: React.FC = () => {
|
|
|
22
18
|
const indicator = searchParams.get('indicator');
|
|
23
19
|
const reportName = location.state?.reportName || '';
|
|
24
20
|
|
|
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
|
-
fetchData();
|
|
51
|
-
}, [startDate, endDate, locationUuids, indicator, reportName]);
|
|
52
|
-
function navigateBack() {
|
|
53
|
-
navigate('/moh-711');
|
|
54
|
-
}
|
|
21
|
+
const {
|
|
22
|
+
rows: patientlist,
|
|
23
|
+
total,
|
|
24
|
+
isTotalExact,
|
|
25
|
+
isLoading,
|
|
26
|
+
page,
|
|
27
|
+
pageSize,
|
|
28
|
+
onPageChange,
|
|
29
|
+
fetchAll,
|
|
30
|
+
} = usePatientList(
|
|
31
|
+
({ startIndex, limit }) =>
|
|
32
|
+
getMoh406PatientList({
|
|
33
|
+
startDate,
|
|
34
|
+
endDate,
|
|
35
|
+
locationUuids,
|
|
36
|
+
indicator,
|
|
37
|
+
reportName,
|
|
38
|
+
startIndex,
|
|
39
|
+
limit,
|
|
40
|
+
}),
|
|
41
|
+
[startDate, endDate, locationUuids, indicator, reportName],
|
|
42
|
+
);
|
|
55
43
|
return (
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
44
|
+
<RegisterLayout
|
|
45
|
+
parentLabel="MOH-711 Report"
|
|
46
|
+
parentPath="/moh-711"
|
|
47
|
+
title="MOH 406 Register"
|
|
48
|
+
isLoading={isLoading}
|
|
49
|
+
isEmpty={patientlist.length === 0}
|
|
50
|
+
page={page}
|
|
51
|
+
pageSize={pageSize}
|
|
52
|
+
total={total}
|
|
53
|
+
isTotalExact={isTotalExact}
|
|
54
|
+
onPageChange={onPageChange}
|
|
55
|
+
fetchAll={fetchAll}
|
|
56
|
+
columns={moh406ExportColumns}
|
|
57
|
+
>
|
|
61
58
|
<div className={styles.tableContainer}>
|
|
62
59
|
<table className={classNames(`${styles.table}`, `${styles.tableBordered}`, `${styles.tableStriped}`)}>
|
|
63
60
|
<thead>
|
|
@@ -388,49 +385,49 @@ const Moh406Register: React.FC = () => {
|
|
|
388
385
|
</thead>
|
|
389
386
|
<tbody>
|
|
390
387
|
<tr>
|
|
391
|
-
<td className={styles.
|
|
392
|
-
<td className={styles.
|
|
393
|
-
<td className={styles.
|
|
394
|
-
<td className={styles.
|
|
395
|
-
<td className={styles.
|
|
396
|
-
<td className={styles.
|
|
397
|
-
<td className={styles.
|
|
398
|
-
<td className={styles.
|
|
399
|
-
<td className={styles.
|
|
400
|
-
<td className={styles.
|
|
401
|
-
<td className={styles.
|
|
402
|
-
<td className={styles.
|
|
403
|
-
<td className={styles.
|
|
404
|
-
<td className={styles.
|
|
405
|
-
<td className={styles.
|
|
406
|
-
<td className={styles.
|
|
407
|
-
<td className={styles.
|
|
408
|
-
<td className={styles.
|
|
409
|
-
<td className={styles.
|
|
410
|
-
<td className={styles.
|
|
411
|
-
<td className={styles.
|
|
412
|
-
<td className={styles.
|
|
413
|
-
<td className={styles.
|
|
414
|
-
<td className={styles.
|
|
415
|
-
<td className={styles.
|
|
416
|
-
<td className={styles.
|
|
417
|
-
<td className={styles.
|
|
418
|
-
<td className={styles.
|
|
419
|
-
<td className={styles.
|
|
420
|
-
<td className={styles.
|
|
421
|
-
<td className={styles.
|
|
422
|
-
<td className={styles.
|
|
423
|
-
<td className={styles.
|
|
424
|
-
<td className={styles.
|
|
425
|
-
<td className={styles.
|
|
426
|
-
<td className={styles.
|
|
427
|
-
<td className={styles.
|
|
428
|
-
<td className={styles.
|
|
429
|
-
<td className={styles.
|
|
430
|
-
<td className={styles.
|
|
431
|
-
<td className={styles.
|
|
432
|
-
<td className={styles.
|
|
433
|
-
<td className={styles.
|
|
388
|
+
<td className={styles.textCentre}>(a)</td>
|
|
389
|
+
<td className={styles.textCentre}>(b)</td>
|
|
390
|
+
<td className={styles.textCentre}>(c)</td>
|
|
391
|
+
<td className={styles.textCentre}>(d)</td>
|
|
392
|
+
<td className={styles.textCentre}>(e)</td>
|
|
393
|
+
<td className={styles.textCentre}>(f)</td>
|
|
394
|
+
<td className={styles.textCentre}>(g)</td>
|
|
395
|
+
<td className={styles.textCentre}>(h)</td>
|
|
396
|
+
<td className={styles.textCentre}>(i)</td>
|
|
397
|
+
<td className={styles.textCentre}>(j)</td>
|
|
398
|
+
<td className={styles.textCentre}>(k)</td>
|
|
399
|
+
<td className={styles.textCentre}>(l)</td>
|
|
400
|
+
<td className={styles.textCentre}>(m)</td>
|
|
401
|
+
<td className={styles.textCentre}>(n)</td>
|
|
402
|
+
<td className={styles.textCentre}>(o)</td>
|
|
403
|
+
<td className={styles.textCentre}>(p)</td>
|
|
404
|
+
<td className={styles.textCentre}>(q)</td>
|
|
405
|
+
<td className={styles.textCentre}>(r)</td>
|
|
406
|
+
<td className={styles.textCentre}>(s)</td>
|
|
407
|
+
<td className={styles.textCentre}>(t)</td>
|
|
408
|
+
<td className={styles.textCentre}>(u)</td>
|
|
409
|
+
<td className={styles.textCentre}>(v)</td>
|
|
410
|
+
<td className={styles.textCentre}>(w)</td>
|
|
411
|
+
<td className={styles.textCentre}>(x)</td>
|
|
412
|
+
<td className={styles.textCentre}>(y)</td>
|
|
413
|
+
<td className={styles.textCentre}>(z)</td>
|
|
414
|
+
<td className={styles.textCentre}>(aa)</td>
|
|
415
|
+
<td className={styles.textCentre}>(ab)</td>
|
|
416
|
+
<td className={styles.textCentre}>(ac)</td>
|
|
417
|
+
<td className={styles.textCentre}>(ad)</td>
|
|
418
|
+
<td className={styles.textCentre}>(ae)</td>
|
|
419
|
+
<td className={styles.textCentre}>(af)</td>
|
|
420
|
+
<td className={styles.textCentre}>(ag)</td>
|
|
421
|
+
<td className={styles.textCentre}>(ah)</td>
|
|
422
|
+
<td className={styles.textCentre}>(ai)</td>
|
|
423
|
+
<td className={styles.textCentre}>(aj)</td>
|
|
424
|
+
<td className={styles.textCentre}>(ak)</td>
|
|
425
|
+
<td className={styles.textCentre}>(al)</td>
|
|
426
|
+
<td className={styles.textCentre}>(am)</td>
|
|
427
|
+
<td className={styles.textCentre}>(an)</td>
|
|
428
|
+
<td className={styles.textCentre}>(ao)</td>
|
|
429
|
+
<td className={styles.textCentre}>(ap)</td>
|
|
430
|
+
<td className={styles.textCentre}>(aq)</td>
|
|
434
431
|
</tr>
|
|
435
432
|
{patientlist?.length > 0 ? (
|
|
436
433
|
patientlist.map((patient, index) => (
|
|
@@ -518,7 +515,7 @@ const Moh406Register: React.FC = () => {
|
|
|
518
515
|
))
|
|
519
516
|
) : (
|
|
520
517
|
<tr>
|
|
521
|
-
<td colSpan={moh406Columns.length} className={styles.
|
|
518
|
+
<td colSpan={moh406Columns.length} className={styles.textCentre}>
|
|
522
519
|
No data available
|
|
523
520
|
</td>
|
|
524
521
|
</tr>
|
|
@@ -526,7 +523,7 @@ const Moh406Register: React.FC = () => {
|
|
|
526
523
|
</tbody>
|
|
527
524
|
</table>
|
|
528
525
|
</div>
|
|
529
|
-
|
|
526
|
+
</RegisterLayout>
|
|
530
527
|
);
|
|
531
528
|
};
|
|
532
529
|
|