@medicus.ai/medicus-report-pdf-generator 1.3.13 → 1.3.15
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/.vscode/settings.json +3 -3
- package/HANDOVER.md +146 -0
- package/README.md +26 -26
- package/app/i18n.config.js +20 -20
- package/app/i18n_wellbeing.config.js +20 -20
- package/app/services/localeService.js +28 -28
- package/assets/Mediclinic/css/nasco_report.css +6297 -6297
- package/assets/Mediclinic/css/nasco_report_rtl.css +851 -851
- package/assets/Mediclinic/css/style.css +33 -33
- package/assets/Mediclinic/js/js.js +112 -112
- package/assets/Mediclinic/js/raphael.js +8437 -8437
- package/assets/arabic.css +275 -275
- package/assets/charts.min.js +7 -7
- package/assets/corporate_report/css/report.css +582 -582
- package/assets/corporate_report/css/report_rtl.css +144 -144
- package/assets/corporate_report/js/js.js +14 -14
- package/assets/data/data.json +124 -124
- package/assets/data/data2.json +675 -675
- package/assets/data/pdf_data_with_history.json +1255 -1255
- package/assets/doctor-note-insight-icon.svg +11 -11
- package/assets/imc/css/style.css +61 -61
- package/assets/jquery-1.4.min.js +151 -151
- package/assets/jquery-2.1.0.min.js +3 -3
- package/assets/js.js +201 -201
- package/assets/medicus_pdf/arabic.css +444 -444
- package/assets/medicus_pdf/styles.css +2427 -2427
- package/assets/print.css +4 -4
- package/assets/qr-code-style.css +68 -68
- package/assets/qrcode.min.js +3 -3
- package/assets/raphael-min.js +10 -10
- package/assets/sanusx/css/sanusx_report.css +707 -707
- package/assets/sizing.js +2 -2
- package/assets/styles.css +1545 -1545
- package/assets/styles.min.css +1358 -1358
- package/assets/translation.js +30 -30
- package/assets/wellbeing/css/nasco_report.css +3472 -3472
- package/assets/wellbeing/css/nasco_report_rtl.css +679 -679
- package/assets/wellbeing/js/js.js +111 -111
- package/assets/wellbeing/js/raphael.js +8437 -8437
- package/base64/cairo-font.js +2 -2
- package/config/Mediclinic.json +37 -37
- package/config/Najeeb.ai.json +35 -35
- package/config/Pha.json +64 -64
- package/config/bionext.json +37 -37
- package/config/default.json +35 -35
- package/config/diagnostikare.json +34 -34
- package/config/maisonsante.json +39 -39
- package/config/nasco.json +35 -35
- package/config/sanitas.json +35 -35
- package/config/sanusx.json +34 -34
- package/config/test.txt +4 -4
- package/data converter.js +53 -53
- package/docs/01-architecture-overview.md +149 -0
- package/docs/02-configuration-and-whitelabelling.md +111 -0
- package/docs/03-templating-and-rendering.md +71 -0
- package/docs/04-report-pipelines.md +128 -0
- package/docs/05-questions-and-data-model.md +67 -0
- package/docs/06-internationalization.md +59 -0
- package/docs/07-email-notifications.md +59 -0
- package/docs/08-known-issues-and-technical-debt.md +41 -0
- package/docs/README.md +22 -0
- package/downloadfile.js +6 -6
- package/example.txt +1188 -1188
- package/index.js +481 -480
- package/lib/big_integral_questionnaire.js +370 -298
- package/lib/corporate_report_generator.js +399 -399
- package/lib/pdf_generator.min.js +525 -525
- package/lib/sanusx_report_generator.js +533 -533
- package/lib/sendEmail.js +343 -343
- package/lib/template.js +2227 -2227
- package/lib/wellbeing_report_generator.js +2164 -2134
- package/locales/ar-AE.json +169 -169
- package/locales/ar-SA.json +169 -169
- package/locales/ar.json +397 -397
- package/locales/de.json +169 -169
- package/locales/en.json +229 -229
- package/locales/fr.json +168 -168
- package/locales/pt.json +165 -165
- package/locales/wellbeing/ar-AE.json +149 -149
- package/locales/wellbeing/ar-SA.json +257 -257
- package/locales/wellbeing/de.json +301 -301
- package/locales/wellbeing/en.json +423 -423
- package/locales/wellbeing/es.json +133 -133
- package/locales/wellbeing/fr.json +121 -121
- package/locales/wellbeing/it-IT.json +121 -121
- package/locales/wellbeing/pt.json +121 -121
- package/locales/wellbeing/tr.json +121 -121
- package/locales/wellbeing/zh-CN.json +121 -121
- package/locales/zh-CN.json +165 -165
- package/package.json +47 -47
- package/preview-big-integral.js +75 -75
- package/run.js +15 -15
- package/templates/Mediclinic/blocks/first-section.html +205 -205
- package/templates/Mediclinic/blocks/footer.html +7 -7
- package/templates/Mediclinic/blocks/header-template.html +5 -5
- package/templates/Mediclinic/blocks/header.html +20 -20
- package/templates/Mediclinic/blocks/patient-table.html +38 -38
- package/templates/Mediclinic/blocks/pdf-header.html +9 -9
- package/templates/Mediclinic/blocks/tips.html +8 -8
- package/templates/Mediclinic/ltr_no_pages.html +37 -37
- package/templates/Mediclinic/rtl_no_pages.html +42 -42
- package/templates/Mediclinic/wellbeing_template.html +41 -41
- package/templates/Pha/blocks/first-section.html +207 -207
- package/templates/Pha/blocks/footer.html +7 -7
- package/templates/Pha/blocks/header-template.html +5 -5
- package/templates/Pha/blocks/header.html +20 -20
- package/templates/Pha/blocks/patient-table.html +38 -38
- package/templates/Pha/blocks/pdf-header.html +8 -8
- package/templates/Pha/blocks/tips.html +8 -8
- package/templates/Pha/ltr_no_pages.html +37 -37
- package/templates/Pha/rtl_no_pages.html +42 -42
- package/templates/Pha/wellbeing_template.html +41 -41
- package/templates/base.html +23 -23
- package/templates/blocks/ar-first-page-header.html +68 -68
- package/templates/blocks/ar-footer.html +54 -54
- package/templates/blocks/ar-header.html +67 -67
- package/templates/blocks/biomarker-compact-ar.html +27 -27
- package/templates/blocks/biomarker-compact.html +27 -27
- package/templates/blocks/biomarker-details.html +41 -41
- package/templates/blocks/biomarker-insight.html +22 -22
- package/templates/blocks/biomarker-min.html +9 -9
- package/templates/blocks/doctor-note.html +11 -11
- package/templates/blocks/footer.html +35 -35
- package/templates/blocks/header-first-page.html +46 -46
- package/templates/blocks/header.html +49 -49
- package/templates/blocks/panel-compact.html +38 -38
- package/templates/blocks/panel-details.html +16 -16
- package/templates/blocks/report-summary.html +16 -16
- package/templates/blocks/section-title.html +4 -4
- package/templates/blocks/signature.html +16 -16
- package/templates/blocks/summary-insight.html +15 -15
- package/templates/blocks/summary.html +9 -9
- package/templates/corporate_report/cover_page.html +23 -23
- package/templates/corporate_report/footer.html +9 -9
- package/templates/corporate_report/ltr_no_pages.html +20 -20
- package/templates/corporate_report/page.html +24 -24
- package/templates/corporate_report/participant_analytics.html +5 -5
- package/templates/corporate_report/rtl_no_pages.html +20 -20
- package/templates/empty.html +10 -10
- package/templates/first_page_head.html +157 -157
- package/templates/imc/first-header-template.html +53 -53
- package/templates/ltr.html +1368 -1368
- package/templates/ltr_no_pages.html +89 -89
- package/templates/maisonsante/blocks/first-section.html +151 -207
- package/templates/maisonsante/blocks/footer.html +7 -7
- package/templates/maisonsante/blocks/header-template.html +5 -5
- package/templates/maisonsante/blocks/header.html +20 -20
- package/templates/maisonsante/blocks/patient-table.html +38 -38
- package/templates/maisonsante/blocks/pdf-header.html +8 -8
- package/templates/maisonsante/blocks/tips.html +8 -8
- package/templates/maisonsante/ltr_no_pages.html +38 -38
- package/templates/maisonsante/rtl_no_pages.html +43 -43
- package/templates/maisonsante/wellbeing_template.html +41 -41
- package/templates/no_pages.html +1224 -1224
- package/templates/popup/popup-template.html +129 -129
- package/templates/rtl_no_pages.html +92 -92
- package/templates/sanusx/blocks/footer.html +6 -6
- package/templates/sanusx/blocks/header.html +20 -20
- package/templates/sanusx/blocks/personal-details.html +123 -123
- package/templates/sanusx/blocks/predictions-section.html +57 -57
- package/templates/sanusx/blocks/recommendations-section.html +6 -6
- package/templates/sanusx/blocks/super-power-section.html +29 -29
- package/templates/sanusx/blocks/tips.html +8 -8
- package/templates/sanusx/ltr_no_pages.html +26 -26
- package/templates/sanusx/rtl_no_pages.html +36 -36
- package/templates/template.html +1377 -1377
- package/templates/wellbeing/blocks/first-section.html +106 -106
- package/templates/wellbeing/blocks/footer.html +7 -7
- package/templates/wellbeing/blocks/header.html +37 -37
- package/templates/wellbeing/blocks/tips.html +8 -8
- package/templates/wellbeing/ltr_no_pages.html +35 -35
- package/templates/wellbeing/rtl_no_pages.html +36 -36
- package/templates/wellbeing/wellbeing_template.html +43 -43
- package/test.js +74 -74
- package/testing-reports/mediclinic/arabic-data.js +0 -439
- package/testing-reports/mediclinic/doctor-data.js +0 -523
- package/testing-reports/mediclinic/with-wellbeing.js +0 -415
- package/testing-reports/pha/notes-example.js +0 -397
package/locales/zh-CN.json
CHANGED
|
@@ -1,166 +1,166 @@
|
|
|
1
|
-
{
|
|
2
|
-
"APPROVED BY": {
|
|
3
|
-
"message": "已批准",
|
|
4
|
-
"description": "before the doctor signature in the bottom of the PDF file"
|
|
5
|
-
},
|
|
6
|
-
"PREPARED FOR": {
|
|
7
|
-
"message": "有备无患",
|
|
8
|
-
"description": "the label before the patient name, in the header of the pages of the PDF file"
|
|
9
|
-
},
|
|
10
|
-
"REFERENCE": {
|
|
11
|
-
"message": "参考编号",
|
|
12
|
-
"description": "the label before the reference ID number of the patient. in the header of the pages of the PDF file"
|
|
13
|
-
},
|
|
14
|
-
"REPORT DATE": {
|
|
15
|
-
"message": "报告日期",
|
|
16
|
-
"description": "The label before the report date. in the header of the pages of the PDF file"
|
|
17
|
-
},
|
|
18
|
-
"LAB": {
|
|
19
|
-
"message": "实验室",
|
|
20
|
-
"description": "The label before the lab name, title, and number. in the header of the first page of the PDF file"
|
|
21
|
-
},
|
|
22
|
-
"Laboratory Report": {
|
|
23
|
-
"message": "实验室报告",
|
|
24
|
-
"description": "The title of the report PDF file"
|
|
25
|
-
},
|
|
26
|
-
"There's more...": {
|
|
27
|
-
"message": "了解更多信息",
|
|
28
|
-
"description": "The title of a section in the PDF to show links to the lab website,the PIN, and the QR code"
|
|
29
|
-
},
|
|
30
|
-
"Access a detailed report online or in our app.": {
|
|
31
|
-
"message": "在线或在我们的应用程序中访问详细报告。",
|
|
32
|
-
"description": "this sentence shows before the links to the lab website or app"
|
|
33
|
-
},
|
|
34
|
-
"1) Visit": {
|
|
35
|
-
"message": "1)访视",
|
|
36
|
-
"description": "A prefix before the link to the lab website"
|
|
37
|
-
},
|
|
38
|
-
"2) Enter this PIN code:": {
|
|
39
|
-
"message": "2)输入这个PIN码:",
|
|
40
|
-
"description": "before the pin code which will be used to access the app"
|
|
41
|
-
},
|
|
42
|
-
"Details": {
|
|
43
|
-
"message": "详情",
|
|
44
|
-
"description": "The title of the detailed report section"
|
|
45
|
-
},
|
|
46
|
-
"Summary": {
|
|
47
|
-
"message": "概要",
|
|
48
|
-
"description": "The title of the section which contains the summary of the report"
|
|
49
|
-
},
|
|
50
|
-
"Page": {
|
|
51
|
-
"message": "页",
|
|
52
|
-
"description": "The page number in the footer of the pages in the PDf file"
|
|
53
|
-
},
|
|
54
|
-
"of": {
|
|
55
|
-
"message": "关于",
|
|
56
|
-
"description": "The page number in the footer of the pages in the PDf file"
|
|
57
|
-
},
|
|
58
|
-
"Reference range": {
|
|
59
|
-
"message": "参考范围",
|
|
60
|
-
"description": "Reference range in the table biomarker header in the PDf file"
|
|
61
|
-
},
|
|
62
|
-
"Last reading": {
|
|
63
|
-
"message": "实验室读数",
|
|
64
|
-
"description": "Last reading in the table biomarker header in the PDf file"
|
|
65
|
-
},
|
|
66
|
-
"Last reading date": {
|
|
67
|
-
"message": "最后读数日期",
|
|
68
|
-
"description": "Last reading date in the table biomarker header in the PDf file"
|
|
69
|
-
},
|
|
70
|
-
"dates": {
|
|
71
|
-
"message": "Dates",
|
|
72
|
-
"description": "last reading of the history dates"
|
|
73
|
-
},
|
|
74
|
-
"smartReportBy": {
|
|
75
|
-
"message": "智能报告人",
|
|
76
|
-
"description": "text showing at the footer of pdf"
|
|
77
|
-
},
|
|
78
|
-
"January": {
|
|
79
|
-
"message": "January",
|
|
80
|
-
"description": "Month name"
|
|
81
|
-
},
|
|
82
|
-
"February": {
|
|
83
|
-
"message": "February",
|
|
84
|
-
"description": "Month name"
|
|
85
|
-
},
|
|
86
|
-
"March": {
|
|
87
|
-
"message": "March",
|
|
88
|
-
"description": "Month name"
|
|
89
|
-
},
|
|
90
|
-
"April": {
|
|
91
|
-
"message": "April",
|
|
92
|
-
"description": "Month name"
|
|
93
|
-
},
|
|
94
|
-
"May": {
|
|
95
|
-
"message": "May",
|
|
96
|
-
"description": "Month name"
|
|
97
|
-
},
|
|
98
|
-
"June": {
|
|
99
|
-
"message": "June",
|
|
100
|
-
"description": "Month name"
|
|
101
|
-
},
|
|
102
|
-
"July": {
|
|
103
|
-
"message": "July",
|
|
104
|
-
"description": "Month name"
|
|
105
|
-
},
|
|
106
|
-
"August": {
|
|
107
|
-
"message": "August",
|
|
108
|
-
"description": "Month name"
|
|
109
|
-
},
|
|
110
|
-
"September": {
|
|
111
|
-
"message": "September",
|
|
112
|
-
"description": "Month name"
|
|
113
|
-
},
|
|
114
|
-
"October": {
|
|
115
|
-
"message": "October",
|
|
116
|
-
"description": "Month name"
|
|
117
|
-
},
|
|
118
|
-
"November": {
|
|
119
|
-
"message": "November",
|
|
120
|
-
"description": "Month name"
|
|
121
|
-
},
|
|
122
|
-
"December": {
|
|
123
|
-
"message": "December",
|
|
124
|
-
"description": "Month name"
|
|
125
|
-
},
|
|
126
|
-
"am": {
|
|
127
|
-
"message": "AM",
|
|
128
|
-
"description": "AM"
|
|
129
|
-
},
|
|
130
|
-
"pm": {
|
|
131
|
-
"message": "PM",
|
|
132
|
-
"description": "PM"
|
|
133
|
-
},
|
|
134
|
-
"BRANCH": {
|
|
135
|
-
"message": "BRANCH",
|
|
136
|
-
"description": "the label before the branch name of the patient. in the header of the pages of the PDF file"
|
|
137
|
-
},
|
|
138
|
-
"doctorContent": {
|
|
139
|
-
"message": "Doctor content",
|
|
140
|
-
"description": "text showing above the detailed list section (CR) as header"
|
|
141
|
-
},
|
|
142
|
-
"mostCommonCausesOfTheObservedValue": {
|
|
143
|
-
"message": "Most common causes of the observed value(s):",
|
|
144
|
-
"description": "text showing above the detailed list section (CR) as a subheader"
|
|
145
|
-
},
|
|
146
|
-
"reportSummary": {
|
|
147
|
-
"message": "报告总结",
|
|
148
|
-
"description": "name of field showing at add report page"
|
|
149
|
-
},
|
|
150
|
-
"reportProperties": {
|
|
151
|
-
"message": "报告属性",
|
|
152
|
-
"description": "Report Properties Label showing at add report page"
|
|
153
|
-
},
|
|
154
|
-
"noteFromDoctor": {
|
|
155
|
-
"message": "来自医生的注解",
|
|
156
|
-
"description": "Doctor App - Insight header text showing for doctor note type"
|
|
157
|
-
},
|
|
158
|
-
"signedBy": {
|
|
159
|
-
"message": "签署人",
|
|
160
|
-
"description": "Label showing above the doctors who signed on this report"
|
|
161
|
-
},
|
|
162
|
-
"hospital": {
|
|
163
|
-
"message": "医院",
|
|
164
|
-
"description": "name of field showing at add user"
|
|
165
|
-
}
|
|
1
|
+
{
|
|
2
|
+
"APPROVED BY": {
|
|
3
|
+
"message": "已批准",
|
|
4
|
+
"description": "before the doctor signature in the bottom of the PDF file"
|
|
5
|
+
},
|
|
6
|
+
"PREPARED FOR": {
|
|
7
|
+
"message": "有备无患",
|
|
8
|
+
"description": "the label before the patient name, in the header of the pages of the PDF file"
|
|
9
|
+
},
|
|
10
|
+
"REFERENCE": {
|
|
11
|
+
"message": "参考编号",
|
|
12
|
+
"description": "the label before the reference ID number of the patient. in the header of the pages of the PDF file"
|
|
13
|
+
},
|
|
14
|
+
"REPORT DATE": {
|
|
15
|
+
"message": "报告日期",
|
|
16
|
+
"description": "The label before the report date. in the header of the pages of the PDF file"
|
|
17
|
+
},
|
|
18
|
+
"LAB": {
|
|
19
|
+
"message": "实验室",
|
|
20
|
+
"description": "The label before the lab name, title, and number. in the header of the first page of the PDF file"
|
|
21
|
+
},
|
|
22
|
+
"Laboratory Report": {
|
|
23
|
+
"message": "实验室报告",
|
|
24
|
+
"description": "The title of the report PDF file"
|
|
25
|
+
},
|
|
26
|
+
"There's more...": {
|
|
27
|
+
"message": "了解更多信息",
|
|
28
|
+
"description": "The title of a section in the PDF to show links to the lab website,the PIN, and the QR code"
|
|
29
|
+
},
|
|
30
|
+
"Access a detailed report online or in our app.": {
|
|
31
|
+
"message": "在线或在我们的应用程序中访问详细报告。",
|
|
32
|
+
"description": "this sentence shows before the links to the lab website or app"
|
|
33
|
+
},
|
|
34
|
+
"1) Visit": {
|
|
35
|
+
"message": "1)访视",
|
|
36
|
+
"description": "A prefix before the link to the lab website"
|
|
37
|
+
},
|
|
38
|
+
"2) Enter this PIN code:": {
|
|
39
|
+
"message": "2)输入这个PIN码:",
|
|
40
|
+
"description": "before the pin code which will be used to access the app"
|
|
41
|
+
},
|
|
42
|
+
"Details": {
|
|
43
|
+
"message": "详情",
|
|
44
|
+
"description": "The title of the detailed report section"
|
|
45
|
+
},
|
|
46
|
+
"Summary": {
|
|
47
|
+
"message": "概要",
|
|
48
|
+
"description": "The title of the section which contains the summary of the report"
|
|
49
|
+
},
|
|
50
|
+
"Page": {
|
|
51
|
+
"message": "页",
|
|
52
|
+
"description": "The page number in the footer of the pages in the PDf file"
|
|
53
|
+
},
|
|
54
|
+
"of": {
|
|
55
|
+
"message": "关于",
|
|
56
|
+
"description": "The page number in the footer of the pages in the PDf file"
|
|
57
|
+
},
|
|
58
|
+
"Reference range": {
|
|
59
|
+
"message": "参考范围",
|
|
60
|
+
"description": "Reference range in the table biomarker header in the PDf file"
|
|
61
|
+
},
|
|
62
|
+
"Last reading": {
|
|
63
|
+
"message": "实验室读数",
|
|
64
|
+
"description": "Last reading in the table biomarker header in the PDf file"
|
|
65
|
+
},
|
|
66
|
+
"Last reading date": {
|
|
67
|
+
"message": "最后读数日期",
|
|
68
|
+
"description": "Last reading date in the table biomarker header in the PDf file"
|
|
69
|
+
},
|
|
70
|
+
"dates": {
|
|
71
|
+
"message": "Dates",
|
|
72
|
+
"description": "last reading of the history dates"
|
|
73
|
+
},
|
|
74
|
+
"smartReportBy": {
|
|
75
|
+
"message": "智能报告人",
|
|
76
|
+
"description": "text showing at the footer of pdf"
|
|
77
|
+
},
|
|
78
|
+
"January": {
|
|
79
|
+
"message": "January",
|
|
80
|
+
"description": "Month name"
|
|
81
|
+
},
|
|
82
|
+
"February": {
|
|
83
|
+
"message": "February",
|
|
84
|
+
"description": "Month name"
|
|
85
|
+
},
|
|
86
|
+
"March": {
|
|
87
|
+
"message": "March",
|
|
88
|
+
"description": "Month name"
|
|
89
|
+
},
|
|
90
|
+
"April": {
|
|
91
|
+
"message": "April",
|
|
92
|
+
"description": "Month name"
|
|
93
|
+
},
|
|
94
|
+
"May": {
|
|
95
|
+
"message": "May",
|
|
96
|
+
"description": "Month name"
|
|
97
|
+
},
|
|
98
|
+
"June": {
|
|
99
|
+
"message": "June",
|
|
100
|
+
"description": "Month name"
|
|
101
|
+
},
|
|
102
|
+
"July": {
|
|
103
|
+
"message": "July",
|
|
104
|
+
"description": "Month name"
|
|
105
|
+
},
|
|
106
|
+
"August": {
|
|
107
|
+
"message": "August",
|
|
108
|
+
"description": "Month name"
|
|
109
|
+
},
|
|
110
|
+
"September": {
|
|
111
|
+
"message": "September",
|
|
112
|
+
"description": "Month name"
|
|
113
|
+
},
|
|
114
|
+
"October": {
|
|
115
|
+
"message": "October",
|
|
116
|
+
"description": "Month name"
|
|
117
|
+
},
|
|
118
|
+
"November": {
|
|
119
|
+
"message": "November",
|
|
120
|
+
"description": "Month name"
|
|
121
|
+
},
|
|
122
|
+
"December": {
|
|
123
|
+
"message": "December",
|
|
124
|
+
"description": "Month name"
|
|
125
|
+
},
|
|
126
|
+
"am": {
|
|
127
|
+
"message": "AM",
|
|
128
|
+
"description": "AM"
|
|
129
|
+
},
|
|
130
|
+
"pm": {
|
|
131
|
+
"message": "PM",
|
|
132
|
+
"description": "PM"
|
|
133
|
+
},
|
|
134
|
+
"BRANCH": {
|
|
135
|
+
"message": "BRANCH",
|
|
136
|
+
"description": "the label before the branch name of the patient. in the header of the pages of the PDF file"
|
|
137
|
+
},
|
|
138
|
+
"doctorContent": {
|
|
139
|
+
"message": "Doctor content",
|
|
140
|
+
"description": "text showing above the detailed list section (CR) as header"
|
|
141
|
+
},
|
|
142
|
+
"mostCommonCausesOfTheObservedValue": {
|
|
143
|
+
"message": "Most common causes of the observed value(s):",
|
|
144
|
+
"description": "text showing above the detailed list section (CR) as a subheader"
|
|
145
|
+
},
|
|
146
|
+
"reportSummary": {
|
|
147
|
+
"message": "报告总结",
|
|
148
|
+
"description": "name of field showing at add report page"
|
|
149
|
+
},
|
|
150
|
+
"reportProperties": {
|
|
151
|
+
"message": "报告属性",
|
|
152
|
+
"description": "Report Properties Label showing at add report page"
|
|
153
|
+
},
|
|
154
|
+
"noteFromDoctor": {
|
|
155
|
+
"message": "来自医生的注解",
|
|
156
|
+
"description": "Doctor App - Insight header text showing for doctor note type"
|
|
157
|
+
},
|
|
158
|
+
"signedBy": {
|
|
159
|
+
"message": "签署人",
|
|
160
|
+
"description": "Label showing above the doctors who signed on this report"
|
|
161
|
+
},
|
|
162
|
+
"hospital": {
|
|
163
|
+
"message": "医院",
|
|
164
|
+
"description": "name of field showing at add user"
|
|
165
|
+
}
|
|
166
166
|
}
|
package/package.json
CHANGED
|
@@ -1,47 +1,47 @@
|
|
|
1
|
-
{
|
|
2
|
-
"name": "@medicus.ai/medicus-report-pdf-generator",
|
|
3
|
-
"version": "1.3.
|
|
4
|
-
"description": "Nasco corporate report - latest update in 12/10/2023 - Fix HRC for bionext",
|
|
5
|
-
"main": "index.js",
|
|
6
|
-
"scripts": {
|
|
7
|
-
"start": "node index.js"
|
|
8
|
-
},
|
|
9
|
-
"author": "MEDICUS AI",
|
|
10
|
-
"license": "ISC",
|
|
11
|
-
"dependencies": {
|
|
12
|
-
"babel-preset-env": "^1.7.0",
|
|
13
|
-
"babel-register": "^6.26.0",
|
|
14
|
-
"big-text.js": "^1.0.1",
|
|
15
|
-
"body-parser": "^1.18.3",
|
|
16
|
-
"canvas": "^2.11.2",
|
|
17
|
-
"canvas-constructor": "^3.2.0",
|
|
18
|
-
"chart.js": "^2.7.3",
|
|
19
|
-
"express": "^4.16.4",
|
|
20
|
-
"get-canvas-context": "^1.0.2",
|
|
21
|
-
"hummus": "1.0.111",
|
|
22
|
-
"i18n": "^0.8.3",
|
|
23
|
-
"i18n-nodejs": "^3.0.0",
|
|
24
|
-
"jquery": "^3.3.1",
|
|
25
|
-
"jsdom": "^13.1.0",
|
|
26
|
-
"memory-streams": "^0.1.3",
|
|
27
|
-
"node-fetch": "^2.3.0",
|
|
28
|
-
"node-pdftk": "^2.0.2",
|
|
29
|
-
"node-qpdf2": "^6.0.0",
|
|
30
|
-
"nodemailer": "^6.6.0",
|
|
31
|
-
"pdf-lib": "^1.17.1",
|
|
32
|
-
"puppeteer": "^1.15.0",
|
|
33
|
-
"qr-image": "^3.2.0",
|
|
34
|
-
"qrcode": "^1.3.3",
|
|
35
|
-
"self-adapt-fontsize": "^1.0.6",
|
|
36
|
-
"textfit": "^2.3.1"
|
|
37
|
-
},
|
|
38
|
-
"devDependencies": {
|
|
39
|
-
"@babel/core": "^7.2.2",
|
|
40
|
-
"babel-core": "^6.26.3",
|
|
41
|
-
"babel-loader": "^8.0.5",
|
|
42
|
-
"babel-polyfill": "^6.26.0",
|
|
43
|
-
"babel-preset-es2015": "^6.24.1",
|
|
44
|
-
"babel-preset-stage-0": "^6.24.1",
|
|
45
|
-
"webpack": "^4.28.4"
|
|
46
|
-
}
|
|
47
|
-
}
|
|
1
|
+
{
|
|
2
|
+
"name": "@medicus.ai/medicus-report-pdf-generator",
|
|
3
|
+
"version": "1.3.15",
|
|
4
|
+
"description": "Nasco corporate report - latest update in 12/10/2023 - Fix HRC for bionext",
|
|
5
|
+
"main": "index.js",
|
|
6
|
+
"scripts": {
|
|
7
|
+
"start": "node index.js"
|
|
8
|
+
},
|
|
9
|
+
"author": "MEDICUS AI",
|
|
10
|
+
"license": "ISC",
|
|
11
|
+
"dependencies": {
|
|
12
|
+
"babel-preset-env": "^1.7.0",
|
|
13
|
+
"babel-register": "^6.26.0",
|
|
14
|
+
"big-text.js": "^1.0.1",
|
|
15
|
+
"body-parser": "^1.18.3",
|
|
16
|
+
"canvas": "^2.11.2",
|
|
17
|
+
"canvas-constructor": "^3.2.0",
|
|
18
|
+
"chart.js": "^2.7.3",
|
|
19
|
+
"express": "^4.16.4",
|
|
20
|
+
"get-canvas-context": "^1.0.2",
|
|
21
|
+
"hummus": "1.0.111",
|
|
22
|
+
"i18n": "^0.8.3",
|
|
23
|
+
"i18n-nodejs": "^3.0.0",
|
|
24
|
+
"jquery": "^3.3.1",
|
|
25
|
+
"jsdom": "^13.1.0",
|
|
26
|
+
"memory-streams": "^0.1.3",
|
|
27
|
+
"node-fetch": "^2.3.0",
|
|
28
|
+
"node-pdftk": "^2.0.2",
|
|
29
|
+
"node-qpdf2": "^6.0.0",
|
|
30
|
+
"nodemailer": "^6.6.0",
|
|
31
|
+
"pdf-lib": "^1.17.1",
|
|
32
|
+
"puppeteer": "^1.15.0",
|
|
33
|
+
"qr-image": "^3.2.0",
|
|
34
|
+
"qrcode": "^1.3.3",
|
|
35
|
+
"self-adapt-fontsize": "^1.0.6",
|
|
36
|
+
"textfit": "^2.3.1"
|
|
37
|
+
},
|
|
38
|
+
"devDependencies": {
|
|
39
|
+
"@babel/core": "^7.2.2",
|
|
40
|
+
"babel-core": "^6.26.3",
|
|
41
|
+
"babel-loader": "^8.0.5",
|
|
42
|
+
"babel-polyfill": "^6.26.0",
|
|
43
|
+
"babel-preset-es2015": "^6.24.1",
|
|
44
|
+
"babel-preset-stage-0": "^6.24.1",
|
|
45
|
+
"webpack": "^4.28.4"
|
|
46
|
+
}
|
|
47
|
+
}
|
package/preview-big-integral.js
CHANGED
|
@@ -1,75 +1,75 @@
|
|
|
1
|
-
'use strict';
|
|
2
|
-
/**
|
|
3
|
-
* Standalone HTML preview for the Big Integral Questionnaire section.
|
|
4
|
-
* Writes output/big-integral-preview.html and opens it in the default browser.
|
|
5
|
-
* Does NOT need puppeteer or canvas.
|
|
6
|
-
*/
|
|
7
|
-
|
|
8
|
-
const fs = require('fs');
|
|
9
|
-
const path = require('path');
|
|
10
|
-
|
|
11
|
-
const { renderBigIntegralQuestionnaire } = require('./lib/big_integral_questionnaire');
|
|
12
|
-
|
|
13
|
-
// Load raw config
|
|
14
|
-
const clientConfig = JSON.parse(
|
|
15
|
-
fs.readFileSync(path.resolve(__dirname, 'config/maisonsante.json'), 'utf8')
|
|
16
|
-
);
|
|
17
|
-
|
|
18
|
-
const sectionHtml = renderBigIntegralQuestionnaire({ clientConfig });
|
|
19
|
-
|
|
20
|
-
const fullHtml = `<!DOCTYPE html>
|
|
21
|
-
<html lang="en">
|
|
22
|
-
<head>
|
|
23
|
-
<meta charset="UTF-8">
|
|
24
|
-
<meta name="viewport" content="width=device-width,initial-scale=1">
|
|
25
|
-
<title>Big Integral Questionnaire — Design Preview</title>
|
|
26
|
-
<link href="https://fonts.googleapis.com/css2?family=Open+Sans:wght@400;600;700&display=swap" rel="stylesheet">
|
|
27
|
-
<style>
|
|
28
|
-
*, *::before, *::after { box-sizing: border-box; }
|
|
29
|
-
body {
|
|
30
|
-
font-family: 'Open Sans', sans-serif;
|
|
31
|
-
background: #f4f6fb;
|
|
32
|
-
margin: 0;
|
|
33
|
-
padding: 20px;
|
|
34
|
-
}
|
|
35
|
-
.page-title {
|
|
36
|
-
font-size: 15px;
|
|
37
|
-
font-weight: 700;
|
|
38
|
-
color: #0F2062;
|
|
39
|
-
margin-bottom: 6px;
|
|
40
|
-
letter-spacing: .5px;
|
|
41
|
-
}
|
|
42
|
-
.page-sub {
|
|
43
|
-
font-size: 11px;
|
|
44
|
-
color: #888;
|
|
45
|
-
margin-bottom: 30px;
|
|
46
|
-
}
|
|
47
|
-
.a4-wrapper {
|
|
48
|
-
width: 794px; /* approximate A4 @ 96 dpi */
|
|
49
|
-
margin: 0 auto;
|
|
50
|
-
background: #fff;
|
|
51
|
-
border-radius: 6px;
|
|
52
|
-
box-shadow: 0 4px 20px rgba(0,0,0,.10);
|
|
53
|
-
padding: 32px 36px;
|
|
54
|
-
}
|
|
55
|
-
</style>
|
|
56
|
-
</head>
|
|
57
|
-
<body>
|
|
58
|
-
<div class="a4-wrapper">
|
|
59
|
-
<div class="page-title">Maison Sante — Doctor PDF: Big Integral Questionnaire</div>
|
|
60
|
-
<div class="page-sub">Maison Sante colors — dummy data — Doctor PDF only</div>
|
|
61
|
-
${sectionHtml}
|
|
62
|
-
</div>
|
|
63
|
-
</body>
|
|
64
|
-
</html>`;
|
|
65
|
-
|
|
66
|
-
const outPath = path.resolve(__dirname, 'output/big-integral-preview.html');
|
|
67
|
-
fs.mkdirSync(path.dirname(outPath), { recursive: true });
|
|
68
|
-
fs.writeFileSync(outPath, fullHtml, 'utf8');
|
|
69
|
-
console.log('Preview written to:', outPath);
|
|
70
|
-
|
|
71
|
-
// Open in default browser (Windows)
|
|
72
|
-
const { exec } = require('child_process');
|
|
73
|
-
exec(`start "" "${outPath}"`, (err) => {
|
|
74
|
-
if (err) console.log('Open manually:', outPath);
|
|
75
|
-
});
|
|
1
|
+
'use strict';
|
|
2
|
+
/**
|
|
3
|
+
* Standalone HTML preview for the Big Integral Questionnaire section.
|
|
4
|
+
* Writes output/big-integral-preview.html and opens it in the default browser.
|
|
5
|
+
* Does NOT need puppeteer or canvas.
|
|
6
|
+
*/
|
|
7
|
+
|
|
8
|
+
const fs = require('fs');
|
|
9
|
+
const path = require('path');
|
|
10
|
+
|
|
11
|
+
const { renderBigIntegralQuestionnaire } = require('./lib/big_integral_questionnaire');
|
|
12
|
+
|
|
13
|
+
// Load raw config
|
|
14
|
+
const clientConfig = JSON.parse(
|
|
15
|
+
fs.readFileSync(path.resolve(__dirname, 'config/maisonsante.json'), 'utf8')
|
|
16
|
+
);
|
|
17
|
+
|
|
18
|
+
const sectionHtml = renderBigIntegralQuestionnaire({ clientConfig });
|
|
19
|
+
|
|
20
|
+
const fullHtml = `<!DOCTYPE html>
|
|
21
|
+
<html lang="en">
|
|
22
|
+
<head>
|
|
23
|
+
<meta charset="UTF-8">
|
|
24
|
+
<meta name="viewport" content="width=device-width,initial-scale=1">
|
|
25
|
+
<title>Big Integral Questionnaire — Design Preview</title>
|
|
26
|
+
<link href="https://fonts.googleapis.com/css2?family=Open+Sans:wght@400;600;700&display=swap" rel="stylesheet">
|
|
27
|
+
<style>
|
|
28
|
+
*, *::before, *::after { box-sizing: border-box; }
|
|
29
|
+
body {
|
|
30
|
+
font-family: 'Open Sans', sans-serif;
|
|
31
|
+
background: #f4f6fb;
|
|
32
|
+
margin: 0;
|
|
33
|
+
padding: 20px;
|
|
34
|
+
}
|
|
35
|
+
.page-title {
|
|
36
|
+
font-size: 15px;
|
|
37
|
+
font-weight: 700;
|
|
38
|
+
color: #0F2062;
|
|
39
|
+
margin-bottom: 6px;
|
|
40
|
+
letter-spacing: .5px;
|
|
41
|
+
}
|
|
42
|
+
.page-sub {
|
|
43
|
+
font-size: 11px;
|
|
44
|
+
color: #888;
|
|
45
|
+
margin-bottom: 30px;
|
|
46
|
+
}
|
|
47
|
+
.a4-wrapper {
|
|
48
|
+
width: 794px; /* approximate A4 @ 96 dpi */
|
|
49
|
+
margin: 0 auto;
|
|
50
|
+
background: #fff;
|
|
51
|
+
border-radius: 6px;
|
|
52
|
+
box-shadow: 0 4px 20px rgba(0,0,0,.10);
|
|
53
|
+
padding: 32px 36px;
|
|
54
|
+
}
|
|
55
|
+
</style>
|
|
56
|
+
</head>
|
|
57
|
+
<body>
|
|
58
|
+
<div class="a4-wrapper">
|
|
59
|
+
<div class="page-title">Maison Sante — Doctor PDF: Big Integral Questionnaire</div>
|
|
60
|
+
<div class="page-sub">Maison Sante colors — dummy data — Doctor PDF only</div>
|
|
61
|
+
${sectionHtml}
|
|
62
|
+
</div>
|
|
63
|
+
</body>
|
|
64
|
+
</html>`;
|
|
65
|
+
|
|
66
|
+
const outPath = path.resolve(__dirname, 'output/big-integral-preview.html');
|
|
67
|
+
fs.mkdirSync(path.dirname(outPath), { recursive: true });
|
|
68
|
+
fs.writeFileSync(outPath, fullHtml, 'utf8');
|
|
69
|
+
console.log('Preview written to:', outPath);
|
|
70
|
+
|
|
71
|
+
// Open in default browser (Windows)
|
|
72
|
+
const { exec } = require('child_process');
|
|
73
|
+
exec(`start "" "${outPath}"`, (err) => {
|
|
74
|
+
if (err) console.log('Open manually:', outPath);
|
|
75
|
+
});
|
package/run.js
CHANGED
|
@@ -1,15 +1,15 @@
|
|
|
1
|
-
const {generateMedicusPDF} = require('./index');
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
process.on('message', async ({data, isDebugging}) => {
|
|
5
|
-
let result = null;
|
|
6
|
-
try {
|
|
7
|
-
result = await generateMedicusPDF(data, isDebugging);
|
|
8
|
-
} catch (e) {
|
|
9
|
-
result = e;
|
|
10
|
-
}
|
|
11
|
-
|
|
12
|
-
process.send(result);
|
|
13
|
-
process.exit();
|
|
14
|
-
});
|
|
15
|
-
|
|
1
|
+
const {generateMedicusPDF} = require('./index');
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
process.on('message', async ({data, isDebugging}) => {
|
|
5
|
+
let result = null;
|
|
6
|
+
try {
|
|
7
|
+
result = await generateMedicusPDF(data, isDebugging);
|
|
8
|
+
} catch (e) {
|
|
9
|
+
result = e;
|
|
10
|
+
}
|
|
11
|
+
|
|
12
|
+
process.send(result);
|
|
13
|
+
process.exit();
|
|
14
|
+
});
|
|
15
|
+
|