@ampath/esm-reports-app 1.0.0-next.7 → 1.0.0-next.71
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/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/299.js +2 -0
- package/dist/299.js.LICENSE.txt +3 -0
- package/dist/299.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/354.js +2 -0
- package/dist/354.js.LICENSE.txt +20 -0
- package/dist/354.js.map +1 -0
- package/dist/410.js +1 -0
- package/dist/410.js.map +1 -0
- package/dist/457.js +2 -0
- package/dist/457.js.LICENSE.txt +261 -0
- package/dist/457.js.map +1 -0
- package/dist/478.js +1 -1
- package/dist/478.js.map +1 -1
- package/dist/480.js +1 -0
- package/dist/540.js +1 -1
- package/dist/540.js.map +1 -1
- package/dist/55.js +1 -1
- package/dist/580.js +1 -0
- package/dist/580.js.map +1 -0
- package/dist/600.js +2 -0
- package/dist/600.js.LICENSE.txt +35 -0
- package/dist/600.js.map +1 -0
- package/dist/652.js +1 -1
- package/dist/781.js +1 -0
- package/dist/781.js.map +1 -0
- package/dist/919.css +1 -0
- package/dist/919.css.map +1 -0
- package/dist/919.js +1 -0
- package/dist/919.js.map +1 -0
- package/dist/961.js +1 -1
- package/dist/961.js.map +1 -1
- package/dist/99.js +1 -1
- package/dist/99.js.map +1 -0
- 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 +4 -2
- package/src/common/daily-summary-table.tsx +55 -0
- package/src/common/linelist-table/index.ts +3 -0
- package/src/common/linelist-table/linelist-columns.ts +48 -0
- package/src/common/linelist-table/linelist-table.component.tsx +442 -0
- package/src/common/linelist-table/linelist-table.scss +306 -0
- package/src/common/linelist-table/linelist-table.test.tsx +120 -0
- package/src/common/linelist-table/use-all-rows.ts +93 -0
- package/src/common/linelist-table/use-column-layout.ts +123 -0
- 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 +317 -99
- package/src/common/report-filters/report-filters.scss +255 -32
- package/src/common/report-filters/types.ts +79 -0
- package/src/common/report-filters/use-restore-period.ts +43 -0
- package/src/common/report-header/index.ts +1 -0
- package/src/common/report-header/use-location-details.ts +58 -0
- package/src/common/report-page/download-sheet-pdf.ts +59 -0
- package/src/common/report-page/index.ts +3 -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 +60 -0
- package/src/common/report-placeholder/has-report-data.ts +15 -0
- package/src/common/report-placeholder/index.ts +3 -0
- package/src/common/report-placeholder/report-placeholder.component.tsx +81 -0
- package/src/common/report-placeholder/report-placeholder.scss +48 -0
- package/src/common/report-placeholder/use-generated-location.ts +62 -0
- package/src/common/report-register/index.ts +6 -0
- package/src/common/report-register/register-columns.ts +46 -0
- package/src/common/report-register/register-layout.component.tsx +265 -0
- package/src/common/report-register/register-layout.scss +150 -0
- package/src/common/report-register/register-table.scss +71 -0
- package/src/common/report-register/report-parents.ts +27 -0
- package/src/common/report-register/rows-to-csv.ts +89 -0
- package/src/common/report-register/use-location-name.ts +54 -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 +189 -18
- package/src/dashboard/reports-dashboard.module.scss +357 -14
- package/src/index.ts +13 -1
- package/src/registers/moh-240/moh-240-register.scss +41 -0
- package/src/registers/moh-240/moh-240.component.test.tsx +166 -0
- package/src/registers/moh-240/moh-240.component.tsx +164 -0
- package/src/registers/moh-362/moh-362-lab-register.component.tsx +392 -0
- package/src/registers/moh-362/moh-362-linkage-register.component.tsx +120 -0
- package/src/registers/moh-362/moh-362-register.scss +222 -0
- package/src/registers/moh-362/moh-362.component.tsx +99 -0
- package/src/registers/moh-362/moh-362.scss +11 -0
- package/src/registers/moh-362/moh-362.types.ts +97 -0
- package/src/registers/register-catalog.ts +96 -0
- package/src/registers/tb-lab-register/tb-lab-register-table.component.tsx +116 -0
- package/src/registers/tb-lab-register/tb-lab-register-table.scss +123 -0
- package/src/registers/tb-lab-register/tb-lab-register.columns.ts +164 -0
- package/src/registers/tb-lab-register/tb-lab-register.component.test.tsx +232 -0
- package/src/registers/tb-lab-register/tb-lab-register.component.tsx +153 -0
- package/src/reports/datatable-wrapper/datatable-wrapper.component.tsx +63 -48
- package/src/reports/moh-240/moh-240-header.component.tsx +62 -0
- package/src/reports/moh-240/moh-240.columns.ts +113 -0
- package/src/reports/moh-240/moh-240.component.tsx +72 -9
- package/src/reports/moh-240/moh-240.scss +40 -0
- package/src/reports/moh-240/sub-reports/moh-240-register.component.tsx +31 -37
- package/src/reports/moh-240/sub-reports/page-summary.component.tsx +143 -106
- package/src/reports/moh-505/moh-505-header.component.tsx +67 -0
- package/src/reports/moh-505/moh-505.component.tsx +441 -0
- package/src/reports/moh-505/moh-505.scss +117 -0
- package/src/reports/moh-705B/moh-204b-register.component.tsx +244 -0
- package/src/reports/moh-705B/moh-204b.columns.ts +39 -0
- package/src/reports/moh-705B/moh-705b.component.tsx +659 -0
- package/src/reports/moh-705B/moh-705b.scss +172 -0
- package/src/reports/moh-705a/moh-705a.component.tsx +661 -0
- package/src/reports/moh-705a/moh-705a.scss +172 -0
- package/src/reports/moh-705a/registers/moh-204a-register.component.tsx +329 -0
- package/src/reports/moh-705a/registers/moh-204a.columns.ts +57 -0
- package/src/reports/moh-705a/type.ts +6 -0
- package/src/reports/moh-706/moh-706-header.component.tsx +66 -0
- package/src/reports/moh-706/moh-706.component.tsx +150 -24
- package/src/reports/moh-706/moh-706.scss +119 -11
- package/src/reports/moh-706/sub-reports/bacteriology/bacteriology.component.tsx +54 -62
- package/src/reports/moh-706/sub-reports/blood-chemistry/blood-chemistry.component.tsx +228 -317
- package/src/reports/moh-706/sub-reports/drug-susceptibility-testing/drug-susceptibility-testing.component.tsx +31 -46
- package/src/reports/moh-706/sub-reports/haematology/haematology.component.tsx +47 -55
- package/src/reports/moh-706/sub-reports/histology-and-cytology/histology-and-cytology.component.tsx +43 -58
- package/src/reports/moh-706/sub-reports/parasitology/parasitology.component.tsx +31 -39
- package/src/reports/moh-706/sub-reports/serology/serology.component.tsx +26 -34
- package/src/reports/moh-706/sub-reports/specimen-referral-to-higher-levels/specimen-referral-to-higher-levels.component.tsx +9 -24
- package/src/reports/moh-706/sub-reports/urine-analysis/urine-analysis.component.tsx +43 -51
- package/src/reports/moh-710/moh-710.component.tsx +799 -632
- package/src/reports/moh-710/moh-710.scss +142 -21
- package/src/reports/moh-710/registers/moh-510/moh-510.columns.ts +40 -0
- package/src/reports/moh-710/registers/moh-510/moh-510.component.tsx +144 -0
- package/src/reports/moh-710/registers/moh-510/moh-510.scss +130 -0
- package/src/reports/moh-710/registers/moh-511-710-register.component.tsx +268 -0
- package/src/reports/moh-710/registers/moh-511-710.columns.ts +52 -0
- package/src/reports/moh-710/registers/type.ts +31 -0
- package/src/reports/moh-711/moh-711.component.tsx +138 -1269
- package/src/reports/moh-711/moh711.scss +135 -20
- package/src/reports/moh-711/registers/moh-333-register.component.tsx +637 -0
- package/src/reports/moh-711/registers/moh-333.columns.ts +119 -0
- package/src/reports/moh-711/registers/moh-405-register.component.tsx +520 -0
- package/src/reports/moh-711/registers/moh-405.columns.ts +120 -0
- package/src/reports/moh-711/registers/moh-406-register.component.tsx +530 -0
- package/src/reports/moh-711/registers/moh-406.columns.ts +133 -0
- package/src/reports/moh-711/registers/moh-510-register.component.tsx +55 -0
- package/src/reports/moh-711/registers/moh-511-register.component.tsx +270 -0
- package/src/reports/moh-711/registers/moh-511.columns.ts +59 -0
- package/src/reports/moh-711/registers/type.ts +192 -0
- package/src/reports/moh-711/sections/anc.component.tsx +159 -0
- package/src/reports/moh-711/sections/cervical-cancer.component.tsx +148 -0
- package/src/reports/moh-711/sections/chanis.component.tsx +366 -0
- package/src/reports/moh-711/sections/family-planning.component.tsx +221 -0
- package/src/reports/moh-711/sections/gbv.component.tsx +115 -0
- package/src/reports/moh-711/sections/maternity.component.tsx +321 -0
- package/src/reports/moh-711/sections/medical-social-work.component.tsx +73 -0
- package/src/reports/moh-711/sections/other.component.tsx +47 -0
- package/src/reports/moh-711/sections/physiotherapy.component.tsx +61 -0
- package/src/reports/moh-711/sections/pnc.component.tsx +127 -0
- package/src/reports/moh-711/sections/post-abortion.component.tsx +42 -0
- package/src/reports/moh-711/sections/rehabilitation.component.tsx +57 -0
- package/src/reports/moh-711/sections/report-compiled-by.component.tsx +50 -0
- package/src/reports/moh-711/sections/tb-screening.component.tsx +57 -0
- package/src/reports/moh-717/moh-717.component.tsx +149 -985
- package/src/reports/moh-717/moh717.scss +217 -21
- package/src/reports/moh-717/registers/nutrition-register.component.tsx +48 -0
- package/src/reports/moh-717/sections/finance.component.tsx +42 -0
- package/src/reports/moh-717/sections/inpatient.component.tsx +374 -0
- package/src/reports/moh-717/sections/maternity.component.tsx +126 -0
- package/src/reports/moh-717/sections/medical-records.component.tsx +35 -0
- package/src/reports/moh-717/sections/mortuary.component.tsx +43 -0
- package/src/reports/moh-717/sections/operations.component.tsx +53 -0
- package/src/reports/moh-717/sections/orthopaedic-trauma.component.tsx +98 -0
- package/src/reports/moh-717/sections/outpatient.component.tsx +597 -0
- package/src/reports/moh-717/sections/pharmacy.component.tsx +43 -0
- package/src/reports/moh-717/sections/preparedby.component.tsx +52 -0
- package/src/reports/moh-717/sections/special-services.component.tsx +114 -0
- package/src/reports/moh-731/linelist/moh-731-indicators.ts +1122 -0
- package/src/reports/moh-731/linelist/moh-731-linelist-sections.ts +472 -0
- package/src/reports/moh-731/linelist/moh-731-linelist.component.tsx +102 -0
- package/src/reports/moh-731/linelist/use-open-moh-731-linelist.ts +50 -0
- package/src/reports/moh-731/moh-731.component.tsx +266 -0
- package/src/reports/moh-731/moh-731.scss +499 -0
- package/src/reports/moh-731/registers/moh-366.columns.ts +38 -0
- package/src/reports/moh-731/registers/moh-366.component.tsx +471 -0
- package/src/reports/moh-731/registers/prep-register.component.tsx +284 -0
- package/src/reports/moh-731/registers/prep.columns.ts +34 -0
- package/src/reports/moh-731/sections/hiv-and-tb-treatment.component.tsx +1206 -0
- package/src/reports/moh-731/sections/hiv-testing-and-pre-exposure.component.tsx +727 -0
- package/src/reports/moh-731/sections/pmtct.component.tsx +572 -0
- package/src/reports/moh-731/summary/moh-731-summary.component.tsx +313 -0
- package/src/reports/moh-731/summary/moh-731-summary.config.ts +529 -0
- package/src/reports/moh-731/summary/moh-731-summary.scss +242 -0
- package/src/reports/moh-740/moh-740.component.scss +202 -0
- package/src/reports/moh-740/moh-740.component.tsx +1332 -0
- package/src/reports/moh-740/moh-740.resource.ts +54 -0
- package/src/reports/moh-740/registers/moh-222-daily-register/moh-222-daily-register.tsx +149 -0
- package/src/reports/moh-740/registers/moh-270-permanent-register/moh-270-permanent-register.tsx +123 -0
- package/src/reports/moh-740/registers/moh-740-patient-list.scss +0 -0
- package/src/reports/moh-740/registers/moh-740-patient-list.tsx +60 -0
- package/src/reports/moh-740/registers/moh-740.columns.ts +54 -0
- package/src/reports/moh-740/shared/data-cell/data-cell.scss +6 -0
- package/src/reports/moh-740/shared/data-cell/data-cell.tsx +23 -0
- package/src/reports/moh-740/shared/utils/indicator-register-map.ts +159 -0
- package/src/reports/moh-740/types/index.ts +223 -0
- package/src/reports/moh-745/moh-745.component.tsx +1021 -0
- package/src/reports/moh-745/moh-745.scss +132 -0
- package/src/reports/moh-745/registers/moh-412-register.component.tsx +249 -0
- package/src/reports/moh-745/registers/moh-412.columns.ts +52 -0
- package/src/reports/moh-745/registers/type.ts +181 -0
- package/src/reports/table-wrapper/table-row-mapper.component.tsx +57 -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-362.resource.ts +27 -0
- package/src/resources/moh-505.resource.ts +69 -0
- package/src/resources/moh-705.resource.ts +106 -0
- package/src/resources/moh-706.resource.ts +80 -0
- package/src/resources/moh-710.resource.ts +32 -9
- package/src/resources/moh-711.resource.ts +137 -9
- package/src/resources/moh-717.resource.ts +26 -9
- package/src/resources/moh-731.resource.ts +90 -0
- package/src/resources/moh-745.resource.ts +76 -0
- package/src/resources/patient-list-page.ts +65 -0
- package/src/root.component.tsx +59 -8
- package/src/root.scss +36 -0
- package/src/routes.json +3 -1
- package/src/utils/format-indicator.ts +39 -0
- package/src/utils/get-base-url.ts +39 -7
- package/src/utils/utils.ts +36 -0
- package/tsconfig.json +1 -1
- package/webpack.config.js +22 -1
- package/dist/138.js +0 -2
- package/dist/138.js.LICENSE.txt +0 -20
- package/dist/138.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/711.js +0 -1
- package/dist/711.js.map +0 -1
- package/dist/812.js +0 -1
- package/dist/812.js.map +0 -1
- package/dist/ampath-esm-reports-app.js.buildmanifest.json +0 -539
- package/dist/main.js +0 -1
- package/dist/main.js.map +0 -1
|
@@ -1,41 +1,162 @@
|
|
|
1
|
+
@use '@openmrs/esm-styleguide/src/vars' as *;
|
|
1
2
|
|
|
2
|
-
|
|
3
|
-
|
|
3
|
+
/* MOH-710 laid out for A4, on the same scale as MOH-711, MOH-740 and MOH-745.
|
|
4
|
+
Its 106 rows across eleven tables run to about two pages, so this is a
|
|
5
|
+
flowing document: the blocks share their edges, and a lettered section is
|
|
6
|
+
kept whole across a page break. */
|
|
7
|
+
|
|
8
|
+
$ink: #000;
|
|
9
|
+
$bar: #d9d9d9;
|
|
10
|
+
$rule: 1px solid $ink;
|
|
11
|
+
|
|
12
|
+
$text: 7pt;
|
|
13
|
+
$title: 7.5pt;
|
|
14
|
+
$meta: 6.5pt;
|
|
15
|
+
|
|
16
|
+
$pad: 3mm;
|
|
17
|
+
|
|
18
|
+
/* Masthead */
|
|
19
|
+
|
|
20
|
+
.mainTitleBox {
|
|
21
|
+
padding: $pad;
|
|
22
|
+
text-align: center;
|
|
23
|
+
border: $rule;
|
|
4
24
|
}
|
|
5
25
|
|
|
6
|
-
.
|
|
7
|
-
|
|
8
|
-
margin: 0 2rem;
|
|
9
|
-
margin-top: 0.5px;
|
|
26
|
+
.ministry {
|
|
27
|
+
font-size: $meta;
|
|
10
28
|
}
|
|
11
29
|
|
|
12
|
-
.
|
|
13
|
-
|
|
14
|
-
|
|
30
|
+
.reportTitle {
|
|
31
|
+
font-size: $title;
|
|
32
|
+
font-weight: 700;
|
|
33
|
+
color: $ink;
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
/* Facility and period strip, joined to the masthead above */
|
|
37
|
+
|
|
38
|
+
.location {
|
|
39
|
+
display: flex;
|
|
40
|
+
flex-wrap: nowrap;
|
|
41
|
+
align-items: baseline;
|
|
42
|
+
justify-content: space-between;
|
|
43
|
+
gap: 2.5mm;
|
|
44
|
+
padding: 2mm $pad;
|
|
45
|
+
font-size: $meta;
|
|
46
|
+
white-space: nowrap;
|
|
47
|
+
border: $rule;
|
|
48
|
+
border-top: none;
|
|
15
49
|
}
|
|
16
50
|
|
|
17
|
-
.
|
|
18
|
-
|
|
51
|
+
.line,
|
|
52
|
+
.shortLine {
|
|
53
|
+
display: inline-block;
|
|
54
|
+
padding: 0 0.5mm;
|
|
55
|
+
margin-left: 1mm;
|
|
56
|
+
overflow: hidden;
|
|
57
|
+
font-weight: 600;
|
|
58
|
+
text-align: center;
|
|
59
|
+
text-overflow: ellipsis;
|
|
60
|
+
vertical-align: bottom;
|
|
61
|
+
border-bottom: $rule;
|
|
62
|
+
}
|
|
63
|
+
|
|
64
|
+
.line {
|
|
65
|
+
width: 26mm;
|
|
66
|
+
}
|
|
67
|
+
|
|
68
|
+
.shortLine {
|
|
69
|
+
width: 14mm;
|
|
70
|
+
}
|
|
71
|
+
|
|
72
|
+
/* A lettered section, kept off a page break so a table never splits from the
|
|
73
|
+
heading that names it. Sections share edges rather than sitting apart. */
|
|
74
|
+
|
|
75
|
+
.container {
|
|
76
|
+
border: $rule;
|
|
77
|
+
border-top: none;
|
|
78
|
+
break-inside: avoid;
|
|
79
|
+
page-break-inside: avoid;
|
|
19
80
|
}
|
|
20
81
|
|
|
21
82
|
.title {
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
83
|
+
padding: 1.5mm $pad;
|
|
84
|
+
font-size: $text;
|
|
85
|
+
font-weight: 700;
|
|
86
|
+
color: $ink;
|
|
87
|
+
text-align: left;
|
|
88
|
+
background-color: $bar;
|
|
89
|
+
border-bottom: $rule;
|
|
90
|
+
break-after: avoid;
|
|
91
|
+
page-break-after: avoid;
|
|
25
92
|
}
|
|
93
|
+
|
|
94
|
+
.tableContainer {
|
|
95
|
+
overflow-x: auto;
|
|
96
|
+
padding: $pad;
|
|
97
|
+
|
|
98
|
+
& + .tableContainer {
|
|
99
|
+
padding-top: 0;
|
|
100
|
+
}
|
|
101
|
+
}
|
|
102
|
+
|
|
26
103
|
.table {
|
|
27
|
-
width:
|
|
104
|
+
width: 100%;
|
|
28
105
|
border-collapse: collapse;
|
|
29
|
-
|
|
30
106
|
}
|
|
31
107
|
|
|
32
108
|
.tableBordered td,
|
|
33
109
|
.tableBordered th {
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
110
|
+
padding: 1mm 1.5mm;
|
|
111
|
+
font-size: $text;
|
|
112
|
+
text-align: left;
|
|
113
|
+
border: $rule;
|
|
114
|
+
}
|
|
115
|
+
|
|
116
|
+
.tableBordered th {
|
|
117
|
+
font-weight: 700;
|
|
118
|
+
color: $ink;
|
|
119
|
+
background-color: #f0f0f0;
|
|
37
120
|
}
|
|
38
121
|
|
|
39
122
|
.tableStriped tbody tr:nth-of-type(odd) {
|
|
40
|
-
background-color: #
|
|
41
|
-
}
|
|
123
|
+
background-color: #fafafa;
|
|
124
|
+
}
|
|
125
|
+
|
|
126
|
+
@media screen {
|
|
127
|
+
.tableStriped tbody tr:hover {
|
|
128
|
+
background-color: $brand-primary-10;
|
|
129
|
+
}
|
|
130
|
+
}
|
|
131
|
+
|
|
132
|
+
/* Sign-off, enclosed by the form rather than floating beneath it. Three fields
|
|
133
|
+
across the sheet, so its rules can be wider than the header strip's five. */
|
|
134
|
+
|
|
135
|
+
.signOff {
|
|
136
|
+
display: flex;
|
|
137
|
+
flex-wrap: nowrap;
|
|
138
|
+
align-items: baseline;
|
|
139
|
+
justify-content: space-between;
|
|
140
|
+
gap: 2.5mm;
|
|
141
|
+
padding: $pad;
|
|
142
|
+
font-size: $meta;
|
|
143
|
+
white-space: nowrap;
|
|
144
|
+
border: $rule;
|
|
145
|
+
border-top: none;
|
|
146
|
+
|
|
147
|
+
.line {
|
|
148
|
+
width: 45mm;
|
|
149
|
+
}
|
|
150
|
+
|
|
151
|
+
.shortLine {
|
|
152
|
+
width: 25mm;
|
|
153
|
+
}
|
|
154
|
+
}
|
|
155
|
+
|
|
156
|
+
/* On paper the striping is screen affordance that prints as grey noise */
|
|
157
|
+
|
|
158
|
+
@media print {
|
|
159
|
+
.tableStriped tbody tr:nth-of-type(odd) {
|
|
160
|
+
background-color: transparent;
|
|
161
|
+
}
|
|
162
|
+
}
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
import { type RegisterColumn } from '../../../../common/report-register/register-columns';
|
|
2
|
+
|
|
3
|
+
/**
|
|
4
|
+
* MOH 204A as the register prints it: one column per cell, in the order they appear.
|
|
5
|
+
*/
|
|
6
|
+
export const moh510ExportColumns: RegisterColumn[] = [
|
|
7
|
+
{ header: 'Date (DD/MM/YYYY) - A', value: (row) => row.date ?? '' },
|
|
8
|
+
{
|
|
9
|
+
header: "Child's Number - B",
|
|
10
|
+
value: (row) => row.child_number ?? '',
|
|
11
|
+
},
|
|
12
|
+
{ header: "Child's Names - C", value: (row) => row.child_names ?? '' },
|
|
13
|
+
{ header: 'Sex - D', value: (row) => row.sex ?? '' },
|
|
14
|
+
{ header: 'Date of Birth - E', value: (row) => row.date_of_birth ?? '' },
|
|
15
|
+
{ header: 'Date first Seen - F', value: (row) => row.date_first_seen ?? '' },
|
|
16
|
+
{ header: "Father's Full Names/Guardian - G", value: (row) => row.father_names ?? '' },
|
|
17
|
+
{ header: "Mother's Full Names/Guardian - H", value: (row) => row.mother_names ?? '' },
|
|
18
|
+
{ header: 'Village /Estate / Landmark - I', value: (row) => row.village_estate_landmark ?? '' },
|
|
19
|
+
{ header: 'Telephone No. - J', value: (row) => row.phone_number ?? '' },
|
|
20
|
+
{ header: 'BCG - K', value: (row) => row.bcg ?? '' },
|
|
21
|
+
{ header: 'Polio birth Dose - L', value: (row) => row.polio_birth_dose ?? '' },
|
|
22
|
+
{ header: 'OPV 1 - M', value: (row) => row.opv_1 ?? '' },
|
|
23
|
+
{ header: 'OPV 2 - N', value: (row) => row.opv_2 ?? '' },
|
|
24
|
+
{ header: 'OPV 3 - O', value: (row) => row.opv_3 ?? '' },
|
|
25
|
+
{ header: 'IPV - P', value: (row) => row.ipv ?? '' },
|
|
26
|
+
{ header: 'DPT / Hep.B / Hib.1 - Q', value: (row) => row.dpt_hep_1 ?? '' },
|
|
27
|
+
{ header: 'DPT / Hep.B / Hib.2 - R', value: (row) => row.dpt_hep_2 ?? '' },
|
|
28
|
+
{ header: 'DPT / Hep.B / Hib.3 - S', value: (row) => row.dpt_hep_3 ?? '' },
|
|
29
|
+
{ header: 'PCV 10 (Pneumococcal) T - AB', value: (row) => row.pneumococcal_1 ?? '' },
|
|
30
|
+
{ header: 'PCV 10 (Pneumococcal) U - AB', value: (row) => row.pneumococcal_2 ?? '' },
|
|
31
|
+
{ header: 'PCV 10 (Pneumococcal) V - AB', value: (row) => row.pneumococcal_3 ?? '' },
|
|
32
|
+
{ header: 'Rota1 - W', value: (row) => row.rotavirus_1 ?? '' },
|
|
33
|
+
{ header: 'Rota2 - X', value: (row) => row.rotavirus_2 ?? '' },
|
|
34
|
+
{ header: 'Vitamin A(6-11 months) - Y', value: (row) => row.vitamin_a_6_11_months ?? '' },
|
|
35
|
+
{ header: 'MR1 - Z', value: (row) => row.measles_rubella_1 ?? '' },
|
|
36
|
+
{ header: 'Yellow Fever - AA', value: (row) => row.yellow_fever ?? '' },
|
|
37
|
+
{ header: 'Fully Immunized Child - AB', value: (row) => row.fully_immunized_child ?? '' },
|
|
38
|
+
{ header: 'MR2 - AC', value: (row) => row.measles_rubella_2 ?? '' },
|
|
39
|
+
{ header: 'Remarks - AD', value: (row) => row.remarks ?? '' },
|
|
40
|
+
];
|
|
@@ -0,0 +1,144 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
|
|
3
|
+
import styles from './moh-510.scss';
|
|
4
|
+
import { useSearchParams } from 'react-router-dom';
|
|
5
|
+
import { RegisterLayout, usePatientList } from '../../../../common/report-register';
|
|
6
|
+
import { getMoh710PatientList } from '../../../../resources/moh-710.resource';
|
|
7
|
+
import { moh510ExportColumns } from './moh-510.columns';
|
|
8
|
+
import { Table, TableBody, TableCell, TableHead, TableHeader, TableRow } from '@carbon/react';
|
|
9
|
+
import classNames from 'classnames';
|
|
10
|
+
|
|
11
|
+
interface Moh510RegisterComponentProps {}
|
|
12
|
+
|
|
13
|
+
const Moh510RegisterComponent: React.FC<Moh510RegisterComponentProps> = () => {
|
|
14
|
+
const [searchParams] = useSearchParams();
|
|
15
|
+
const startDate = searchParams.get('startDate');
|
|
16
|
+
const endDate = searchParams.get('endDate');
|
|
17
|
+
const locationUuids = searchParams.get('locationUuids');
|
|
18
|
+
const indicator = searchParams.get('indicator');
|
|
19
|
+
const reportName = 'moh710Report';
|
|
20
|
+
|
|
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
|
+
getMoh710PatientList({
|
|
33
|
+
startDate: startDate!,
|
|
34
|
+
endDate: endDate!,
|
|
35
|
+
locationUuids: locationUuids!,
|
|
36
|
+
indicator: indicator!,
|
|
37
|
+
startIndex,
|
|
38
|
+
limit,
|
|
39
|
+
reportName: reportName,
|
|
40
|
+
}),
|
|
41
|
+
[startDate, endDate, locationUuids, indicator],
|
|
42
|
+
);
|
|
43
|
+
return (
|
|
44
|
+
<RegisterLayout
|
|
45
|
+
parentLabel="MOH-705A Report"
|
|
46
|
+
parentPath="/moh-705a"
|
|
47
|
+
title="MOH 204A Under-5 Outpatient 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={moh510ExportColumns}
|
|
57
|
+
>
|
|
58
|
+
<div className={styles.tableContainer}>
|
|
59
|
+
<Table className={classNames(`${styles.table}`, `${styles.tableBordered}`, `${styles.tableStriped}`)}>
|
|
60
|
+
<TableHead>
|
|
61
|
+
<TableRow>
|
|
62
|
+
<TableHeader>Date (DD/MM/YYYY)</TableHeader>
|
|
63
|
+
<TableHeader>Serial Number</TableHeader>
|
|
64
|
+
<TableHeader>Child's Number</TableHeader>
|
|
65
|
+
<TableHeader>Child's Names</TableHeader>
|
|
66
|
+
<TableHeader>Sex</TableHeader>
|
|
67
|
+
<TableHeader>Date of Birth</TableHeader>
|
|
68
|
+
<TableHeader>Date first Seen</TableHeader>
|
|
69
|
+
<TableHeader>Father's Full Names/Guardian</TableHeader>
|
|
70
|
+
<TableHeader>Mother's Full Names/Guardian</TableHeader>
|
|
71
|
+
<TableHeader>Village /Estate / Landmark</TableHeader>
|
|
72
|
+
<TableHeader>Telephone No.</TableHeader>
|
|
73
|
+
<TableHeader>BCG</TableHeader>
|
|
74
|
+
<TableHeader>Polio birth Dose</TableHeader>
|
|
75
|
+
<TableHeader>OPV 1</TableHeader>
|
|
76
|
+
<TableHeader>OPV 2</TableHeader>
|
|
77
|
+
<TableHeader>OPV 3</TableHeader>
|
|
78
|
+
<TableHeader>IPV</TableHeader>
|
|
79
|
+
<TableHeader>DPT / Hep.B / Hib.1</TableHeader>
|
|
80
|
+
<TableHeader>DPT / Hep.B / Hib.2</TableHeader>
|
|
81
|
+
<TableHeader>DPT / Hep.B / Hib.3</TableHeader>
|
|
82
|
+
<TableHeader>PCV 10 (Pneumococcal)</TableHeader>
|
|
83
|
+
<TableHeader>PCV 10 (Pneumococcal)</TableHeader>
|
|
84
|
+
<TableHeader>PCV 10 (Pneumococcal)</TableHeader>
|
|
85
|
+
<TableHeader>Rota1</TableHeader>
|
|
86
|
+
<TableHeader>Rota2</TableHeader>
|
|
87
|
+
<TableHeader>Vitamin A(6-11 months)</TableHeader>
|
|
88
|
+
<TableHeader>MR1</TableHeader>
|
|
89
|
+
<TableHeader>Yellow Fever</TableHeader>
|
|
90
|
+
<TableHeader>Fully Immunized Child</TableHeader>
|
|
91
|
+
<TableHeader>MR2</TableHeader>
|
|
92
|
+
<TableHeader>Remarks</TableHeader>
|
|
93
|
+
</TableRow>
|
|
94
|
+
</TableHead>
|
|
95
|
+
<TableBody>
|
|
96
|
+
{patientlist?.length > 0 ? (
|
|
97
|
+
patientlist?.map((patient, i) => (
|
|
98
|
+
<TableRow key={patient.person_id || patient.id}>
|
|
99
|
+
<TableCell>{patient.date}</TableCell>
|
|
100
|
+
<TableCell>{i + 1}</TableCell>
|
|
101
|
+
<TableCell>{patient.child_number}</TableCell>
|
|
102
|
+
<TableCell>{patient.child_names}</TableCell>
|
|
103
|
+
<TableCell>{patient.sex}</TableCell>
|
|
104
|
+
<TableCell>{patient.date_of_birth}</TableCell>
|
|
105
|
+
<TableCell>{patient.date_first_seen}</TableCell>
|
|
106
|
+
<TableCell>{patient.father_names}</TableCell>
|
|
107
|
+
<TableCell>{patient.mother_names}</TableCell>
|
|
108
|
+
<TableCell>{patient.village_estate_landmark}</TableCell>
|
|
109
|
+
<TableCell>{patient.phone_number}</TableCell>
|
|
110
|
+
<TableCell>{patient.bcg}</TableCell>
|
|
111
|
+
<TableCell>{patient.polio_birth_dose}</TableCell>
|
|
112
|
+
<TableCell>{patient.opv_1}</TableCell>
|
|
113
|
+
<TableCell>{patient.opv_2}</TableCell>
|
|
114
|
+
<TableCell>{patient.opv_3}</TableCell>
|
|
115
|
+
<TableCell>{patient.ipv}</TableCell>
|
|
116
|
+
<TableCell>{patient.dpt_hep_1}</TableCell>
|
|
117
|
+
<TableCell>{patient.dpt_hep_2}</TableCell>
|
|
118
|
+
<TableCell>{patient.dpt_hep_3}</TableCell>
|
|
119
|
+
<TableCell>{patient.pneumococcal_1}</TableCell>
|
|
120
|
+
<TableCell>{patient.pneumococcal_2}</TableCell>
|
|
121
|
+
<TableCell>{patient.pneumococcal_3}</TableCell>
|
|
122
|
+
<TableCell>{patient.rotavirus_1}</TableCell>
|
|
123
|
+
<TableCell>{patient.rotavirus_2}</TableCell>
|
|
124
|
+
<TableCell>{patient.vitamin_a_6_11_months}</TableCell>
|
|
125
|
+
<TableCell>{patient.measles_rubella_1}</TableCell>
|
|
126
|
+
<TableCell>{patient.yellow_fever}</TableCell>
|
|
127
|
+
<TableCell>{patient.fully_immunized_child}</TableCell>
|
|
128
|
+
<TableCell>{patient.measles_rubella_2}</TableCell>
|
|
129
|
+
<TableCell>{patient.remarks}</TableCell>
|
|
130
|
+
</TableRow>
|
|
131
|
+
))
|
|
132
|
+
) : (
|
|
133
|
+
<TableRow>
|
|
134
|
+
<TableCell colSpan={28}>No data available</TableCell>
|
|
135
|
+
</TableRow>
|
|
136
|
+
)}
|
|
137
|
+
</TableBody>
|
|
138
|
+
</Table>
|
|
139
|
+
</div>
|
|
140
|
+
</RegisterLayout>
|
|
141
|
+
);
|
|
142
|
+
};
|
|
143
|
+
|
|
144
|
+
export default Moh510RegisterComponent;
|
|
@@ -0,0 +1,130 @@
|
|
|
1
|
+
@use '@openmrs/esm-styleguide/src/vars' as *;
|
|
2
|
+
|
|
3
|
+
/* MOH-705A laid out for A4, on the same scale as the other reports. Its 76 rows
|
|
4
|
+
are a single diagnoses table, so the sheet is one continuous form: masthead,
|
|
5
|
+
facility strip, table and sign-off share their edges. */
|
|
6
|
+
|
|
7
|
+
$ink: #000;
|
|
8
|
+
$rule: 1px solid $ink;
|
|
9
|
+
|
|
10
|
+
$text: 7pt;
|
|
11
|
+
$title: 7.5pt;
|
|
12
|
+
$meta: 6.5pt;
|
|
13
|
+
|
|
14
|
+
$pad: 3mm;
|
|
15
|
+
|
|
16
|
+
.mainTitleBox {
|
|
17
|
+
padding: $pad;
|
|
18
|
+
text-align: center;
|
|
19
|
+
border: $rule;
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
.ministry {
|
|
23
|
+
font-size: $meta;
|
|
24
|
+
}
|
|
25
|
+
|
|
26
|
+
.reportTitle {
|
|
27
|
+
font-size: $title;
|
|
28
|
+
font-weight: 700;
|
|
29
|
+
color: $ink;
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
.location {
|
|
33
|
+
display: flex;
|
|
34
|
+
flex-wrap: nowrap;
|
|
35
|
+
align-items: baseline;
|
|
36
|
+
justify-content: space-between;
|
|
37
|
+
gap: 2.5mm;
|
|
38
|
+
padding: 2mm $pad;
|
|
39
|
+
font-size: $meta;
|
|
40
|
+
white-space: nowrap;
|
|
41
|
+
border: $rule;
|
|
42
|
+
border-top: none;
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
.line,
|
|
46
|
+
.shortLine {
|
|
47
|
+
display: inline-block;
|
|
48
|
+
padding: 0 0.5mm;
|
|
49
|
+
margin-left: 1mm;
|
|
50
|
+
overflow: hidden;
|
|
51
|
+
font-weight: 600;
|
|
52
|
+
text-align: center;
|
|
53
|
+
text-overflow: ellipsis;
|
|
54
|
+
vertical-align: bottom;
|
|
55
|
+
border-bottom: $rule;
|
|
56
|
+
}
|
|
57
|
+
|
|
58
|
+
.line {
|
|
59
|
+
width: 26mm;
|
|
60
|
+
}
|
|
61
|
+
|
|
62
|
+
.shortLine {
|
|
63
|
+
width: 14mm;
|
|
64
|
+
}
|
|
65
|
+
|
|
66
|
+
.container {
|
|
67
|
+
overflow-x: auto;
|
|
68
|
+
margin: 0;
|
|
69
|
+
}
|
|
70
|
+
|
|
71
|
+
.table {
|
|
72
|
+
width: 100%;
|
|
73
|
+
border-collapse: collapse;
|
|
74
|
+
}
|
|
75
|
+
|
|
76
|
+
.tableBordered td,
|
|
77
|
+
.tableBordered th {
|
|
78
|
+
padding: 1mm 1.5mm;
|
|
79
|
+
font-size: $text;
|
|
80
|
+
text-align: left;
|
|
81
|
+
border: $rule;
|
|
82
|
+
}
|
|
83
|
+
|
|
84
|
+
.tableBordered th {
|
|
85
|
+
font-weight: 700;
|
|
86
|
+
color: $ink;
|
|
87
|
+
background-color: #f0f0f0;
|
|
88
|
+
}
|
|
89
|
+
|
|
90
|
+
.tableStriped tbody tr:nth-of-type(odd) {
|
|
91
|
+
background-color: #fafafa;
|
|
92
|
+
}
|
|
93
|
+
|
|
94
|
+
@media screen {
|
|
95
|
+
.tableStriped tbody tr:hover {
|
|
96
|
+
background-color: $brand-primary-10;
|
|
97
|
+
}
|
|
98
|
+
}
|
|
99
|
+
|
|
100
|
+
/* Sign-off, enclosed by the form. Three fields across the sheet, so its rules
|
|
101
|
+
are wider than the header strip's five. */
|
|
102
|
+
|
|
103
|
+
.signOff {
|
|
104
|
+
display: flex;
|
|
105
|
+
flex-wrap: nowrap;
|
|
106
|
+
align-items: baseline;
|
|
107
|
+
justify-content: space-between;
|
|
108
|
+
gap: 2.5mm;
|
|
109
|
+
padding: $pad;
|
|
110
|
+
font-size: $meta;
|
|
111
|
+
white-space: nowrap;
|
|
112
|
+
border: $rule;
|
|
113
|
+
border-top: none;
|
|
114
|
+
|
|
115
|
+
.line {
|
|
116
|
+
width: 45mm;
|
|
117
|
+
}
|
|
118
|
+
|
|
119
|
+
.shortLine {
|
|
120
|
+
width: 25mm;
|
|
121
|
+
}
|
|
122
|
+
}
|
|
123
|
+
|
|
124
|
+
/* On paper the striping is screen affordance that prints as grey noise */
|
|
125
|
+
|
|
126
|
+
@media print {
|
|
127
|
+
.tableStriped tbody tr:nth-of-type(odd) {
|
|
128
|
+
background-color: transparent;
|
|
129
|
+
}
|
|
130
|
+
}
|