@kenyaemr/esm-ward-app 8.5.3-pre.73 → 8.5.3-pre.78
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/.turbo/turbo-build.log +2 -1
- package/dist/2557.js +1 -1
- package/dist/2557.js.map +1 -1
- package/dist/3103.js +1 -1
- package/dist/3103.js.map +1 -1
- package/dist/4224.js +1 -1
- package/dist/4224.js.map +1 -1
- package/dist/7179.js +1 -1
- package/dist/7179.js.map +1 -1
- package/dist/7661.js +1 -1
- package/dist/7661.js.map +1 -1
- package/dist/8130.js +1 -1
- package/dist/8130.js.map +1 -1
- package/dist/kenyaemr-esm-ward-app.js.buildmanifest.json +21 -21
- package/dist/main.js +1 -1
- package/dist/main.js.map +1 -1
- package/dist/routes.json +1 -1
- package/package.json +1 -1
- package/src/config-schema.ts +7 -1
- package/src/ward-workspace/admit-patient-form-workspace/admit-patient-form.workspace.tsx +1 -1
- package/src/ward.resource.ts +4 -1
package/dist/routes.json
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"$schema":"https://json.openmrs.org/routes.schema.json","backendDependencies":{"webservices.rest":"^2.2.0","emrapi":"^2.0.0 || 2.0.0-SNAPSHOT"},"optionalBackendDependencies":{"bedmanagement":{"version":"^6.0.0 || 6.0.0-SNAPSHOT","feature":{"flagName":"bedmanagement-module","label":"Ward App Patient Service","description":"This module, if installed, provides services for managing patients admitted to the ward."}}},"extensions":[{"name":"ward-dashboard-link","component":"wardDashboardLink","slot":"homepage-dashboard-slot","meta":{"name":"ward","slot":"ward-dashboard-slot","title":"Wards"}},{"component":"root","name":"ward-dashboard","slot":"ward-dashboard-slot"},{"component":"wardView","name":"ward-view","slot":"ward-view-slot"},{"component":"wardPatientActionButtonExtension","name":"ward-patient-action-button","slot":"action-menu-ward-patient-items-slot"},{"component":"wardPatientNotesActionButtonExtension","name":"ward-inpatient-notes-form-action-button","slot":"action-menu-ward-patient-items-slot"},{"component":"coloredObsTagCardRowExtension","name":"colored-obs-tags-card-row","slot":"ward-patient-card-slot"},{"name":"transfer-swap-patient-siderail-button","slot":"action-menu-ward-patient-items-slot","component":"patientTransferAndSwapWorkspaceSiderailIcon"},{"name":"patient-discharge-siderail-button","slot":"action-menu-ward-patient-items-slot","component":"patientDischargeWorkspaceSideRailIcon"},{"name":"clinical-forms-workspace-siderail-button","component":"clinicalFormWorkspaceSideRailIcon","slot":"action-menu-ward-patient-items-slot"},{"name":"admission-requests-workspace-siderail-button","component":"admissionRequestsWorkspaceSideRailIcon","slot":"action-menu-ward-patient-admission-requests-items-slot"},{"name":"create-admission-request-workspace-siderail-button","component":"createAdmissionEncounterWorkspaceSideRailIcon","slot":"action-menu-ward-patient-admission-requests-items-slot"},{"component":"defaultWardView","name":"default-ward","slot":"default-ward"},{"component":"maternalWardView","name":"maternal-ward","slot":"maternal-ward"},{"component":"patientDischargeDocumentPreview","name":"patient-discharge-document-preview-modal"},{"component":"wardPatientWorkspaceBanner","name":"ward-patient-workspace-banner","slot":"ward-workspace-patient-banner-slot"},{"name":"in-patient-dashboard-link","component":"inPatientChartLink","order":7,"meta":{"slot":"patient-chart-in-patient-dashboard-slot","path":"in-patient","layoutMode":"anchored","columns":1,"columnSpan":1}},{"name":"in-patient-dashboard","slot":"patient-chart-in-patient-dashboard-slot","component":"inPatientChartDashboard","meta":{"fullWidth":false}}],"workspaces":[{"name":"admission-requests-workspace","component":"admissionRequestWorkspace","title":"admissionRequests","type":"pending-admission-requests","width":"wider"},{"name":"create-admission-encounter-workspace","component":"createAdmissionEncounterWorkspace","title":"admitPatient","type":"patient-search-workspace","width":"wider"},{"name":"ward-patient-notes-workspace","component":"wardPatientNotesWorkspace","type":"ward-patient-notes","title":"inpatientNotesWorkspaceTitle"},{"name":"admit-patient-form-workspace","component":"admitPatientFormWorkspace","title":"admissionRequests","type":"admission-requests"},{"name":"ward-patient-workspace","component":"wardPatientWorkspace","type":"ward","title":"Ward patient","width":"extra-wide"},{"name":"patient-transfer-swap-workspace","component":"patientTransferAndSwapWorkspace","title":"transfers","type":"transfer-swap-bed-form"},{"name":"patient-transfer-request-workspace","component":"patientTransferRequestWorkspace","title":"transferRequest","type":"transfer-request-form"},{"name":"patient-discharge-workspace","component":"patientDischargeWorkspace","title":"discharge","width":"extra-wide","canMaximize":true,"type":"ward-patient-discharge"},{"name":"ward-patient-clinical-forms-workspace","component":"patientClinicalFormsWorkspace","title":"clinicalForms","type":"ward-patient-clinical-forms","width":"wider"},{"name":"cancel-admission-request-workspace","component":"cancelAdmissionRequestWorkspace","title":"cancelAdmissionRequest","type":"cancel-admission-request"}],"workspaceGroups":[{"name":"ward-patient","members":["ward-patient-workspace","ward-patient-notes-workspace","patient-transfer-swap-workspace","patient-discharge-workspace","ward-patient-clinical-forms-workspace","add-drug-order","order-basket","add-lab-order"]},{"name":"ward-patient-admission-requests","members":["admission-requests-workspace","create-admission-encounter-workspace"]}],"version":"8.5.3-pre.
|
|
1
|
+
{"$schema":"https://json.openmrs.org/routes.schema.json","backendDependencies":{"webservices.rest":"^2.2.0","emrapi":"^2.0.0 || 2.0.0-SNAPSHOT"},"optionalBackendDependencies":{"bedmanagement":{"version":"^6.0.0 || 6.0.0-SNAPSHOT","feature":{"flagName":"bedmanagement-module","label":"Ward App Patient Service","description":"This module, if installed, provides services for managing patients admitted to the ward."}}},"extensions":[{"name":"ward-dashboard-link","component":"wardDashboardLink","slot":"homepage-dashboard-slot","meta":{"name":"ward","slot":"ward-dashboard-slot","title":"Wards"}},{"component":"root","name":"ward-dashboard","slot":"ward-dashboard-slot"},{"component":"wardView","name":"ward-view","slot":"ward-view-slot"},{"component":"wardPatientActionButtonExtension","name":"ward-patient-action-button","slot":"action-menu-ward-patient-items-slot"},{"component":"wardPatientNotesActionButtonExtension","name":"ward-inpatient-notes-form-action-button","slot":"action-menu-ward-patient-items-slot"},{"component":"coloredObsTagCardRowExtension","name":"colored-obs-tags-card-row","slot":"ward-patient-card-slot"},{"name":"transfer-swap-patient-siderail-button","slot":"action-menu-ward-patient-items-slot","component":"patientTransferAndSwapWorkspaceSiderailIcon"},{"name":"patient-discharge-siderail-button","slot":"action-menu-ward-patient-items-slot","component":"patientDischargeWorkspaceSideRailIcon"},{"name":"clinical-forms-workspace-siderail-button","component":"clinicalFormWorkspaceSideRailIcon","slot":"action-menu-ward-patient-items-slot"},{"name":"admission-requests-workspace-siderail-button","component":"admissionRequestsWorkspaceSideRailIcon","slot":"action-menu-ward-patient-admission-requests-items-slot"},{"name":"create-admission-request-workspace-siderail-button","component":"createAdmissionEncounterWorkspaceSideRailIcon","slot":"action-menu-ward-patient-admission-requests-items-slot"},{"component":"defaultWardView","name":"default-ward","slot":"default-ward"},{"component":"maternalWardView","name":"maternal-ward","slot":"maternal-ward"},{"component":"patientDischargeDocumentPreview","name":"patient-discharge-document-preview-modal"},{"component":"wardPatientWorkspaceBanner","name":"ward-patient-workspace-banner","slot":"ward-workspace-patient-banner-slot"},{"name":"in-patient-dashboard-link","component":"inPatientChartLink","order":7,"meta":{"slot":"patient-chart-in-patient-dashboard-slot","path":"in-patient","layoutMode":"anchored","columns":1,"columnSpan":1}},{"name":"in-patient-dashboard","slot":"patient-chart-in-patient-dashboard-slot","component":"inPatientChartDashboard","meta":{"fullWidth":false}}],"workspaces":[{"name":"admission-requests-workspace","component":"admissionRequestWorkspace","title":"admissionRequests","type":"pending-admission-requests","width":"wider"},{"name":"create-admission-encounter-workspace","component":"createAdmissionEncounterWorkspace","title":"admitPatient","type":"patient-search-workspace","width":"wider"},{"name":"ward-patient-notes-workspace","component":"wardPatientNotesWorkspace","type":"ward-patient-notes","title":"inpatientNotesWorkspaceTitle"},{"name":"admit-patient-form-workspace","component":"admitPatientFormWorkspace","title":"admissionRequests","type":"admission-requests"},{"name":"ward-patient-workspace","component":"wardPatientWorkspace","type":"ward","title":"Ward patient","width":"extra-wide"},{"name":"patient-transfer-swap-workspace","component":"patientTransferAndSwapWorkspace","title":"transfers","type":"transfer-swap-bed-form"},{"name":"patient-transfer-request-workspace","component":"patientTransferRequestWorkspace","title":"transferRequest","type":"transfer-request-form"},{"name":"patient-discharge-workspace","component":"patientDischargeWorkspace","title":"discharge","width":"extra-wide","canMaximize":true,"type":"ward-patient-discharge"},{"name":"ward-patient-clinical-forms-workspace","component":"patientClinicalFormsWorkspace","title":"clinicalForms","type":"ward-patient-clinical-forms","width":"wider"},{"name":"cancel-admission-request-workspace","component":"cancelAdmissionRequestWorkspace","title":"cancelAdmissionRequest","type":"cancel-admission-request"}],"workspaceGroups":[{"name":"ward-patient","members":["ward-patient-workspace","ward-patient-notes-workspace","patient-transfer-swap-workspace","patient-discharge-workspace","ward-patient-clinical-forms-workspace","add-drug-order","order-basket","add-lab-order"]},{"name":"ward-patient-admission-requests","members":["admission-requests-workspace","create-admission-encounter-workspace"]}],"version":"8.5.3-pre.78"}
|
package/package.json
CHANGED
package/src/config-schema.ts
CHANGED
|
@@ -287,7 +287,12 @@ export const configSchema: ConfigSchema = {
|
|
|
287
287
|
admissionRequestFormUuid: {
|
|
288
288
|
_description: 'Admission request form uuid',
|
|
289
289
|
_type: Type.String,
|
|
290
|
-
_default: '
|
|
290
|
+
_default: '0bae7646-b079-4cbb-8130-b24274fc16f7',
|
|
291
|
+
},
|
|
292
|
+
admissionFormUuid: {
|
|
293
|
+
_description: 'Admission form uuid',
|
|
294
|
+
_type: Type.String,
|
|
295
|
+
_default: '49f3686d-b83c-4263-a5a1-89040f643a78',
|
|
291
296
|
},
|
|
292
297
|
conceptUuidForWardAdmission: {
|
|
293
298
|
_description: 'Concept UUID for ward admission',
|
|
@@ -502,6 +507,7 @@ export interface WardConfigObject {
|
|
|
502
507
|
clinicalConsultationEncounterType: string;
|
|
503
508
|
doctorsNoteEncounterType: string;
|
|
504
509
|
admissionRequestFormUuid: string;
|
|
510
|
+
admissionFormUuid: string;
|
|
505
511
|
inPatientForms: Array<{
|
|
506
512
|
label: string;
|
|
507
513
|
uuid: string;
|
|
@@ -88,7 +88,7 @@ const AdmitPatientFormWorkspace: React.FC<WardPatientWorkspaceProps> = ({
|
|
|
88
88
|
setIsSubmitting(true);
|
|
89
89
|
const bedSelected = beds.find((bed) => bed.bedId === values.bedId);
|
|
90
90
|
const obs = formValuesToObs(values, config);
|
|
91
|
-
admitPatient(patient, dispositionType, visit.uuid, obs, values.admissionDate)
|
|
91
|
+
admitPatient(patient, dispositionType, visit.uuid, obs, values.admissionDate, config.admissionFormUuid)
|
|
92
92
|
.then(
|
|
93
93
|
async (response) => {
|
|
94
94
|
if (response.ok) {
|
package/src/ward.resource.ts
CHANGED
|
@@ -14,6 +14,7 @@ export function useCreateEncounter() {
|
|
|
14
14
|
visitUuid: string,
|
|
15
15
|
obs: ObsPayload[] = [],
|
|
16
16
|
dateOfAdmission?: Date,
|
|
17
|
+
formUuid?: string,
|
|
17
18
|
) => {
|
|
18
19
|
const encounterPayload = {
|
|
19
20
|
patient: patient.uuid,
|
|
@@ -28,6 +29,7 @@ export function useCreateEncounter() {
|
|
|
28
29
|
obs,
|
|
29
30
|
visit: visitUuid,
|
|
30
31
|
encounterDatetime: dateOfAdmission?.toISOString() ?? undefined,
|
|
32
|
+
form: formUuid,
|
|
31
33
|
};
|
|
32
34
|
|
|
33
35
|
return openmrsFetch<Encounter>(`${restBaseUrl}/encounter`, {
|
|
@@ -52,6 +54,7 @@ export function useAdmitPatient() {
|
|
|
52
54
|
visitUuid: string,
|
|
53
55
|
obs?: ObsPayload[],
|
|
54
56
|
dateOfAdmission?: Date,
|
|
57
|
+
formUuid?: string,
|
|
55
58
|
) => {
|
|
56
59
|
const encounterType =
|
|
57
60
|
dispositionType === 'ADMIT'
|
|
@@ -59,7 +62,7 @@ export function useAdmitPatient() {
|
|
|
59
62
|
: dispositionType === 'TRANSFER'
|
|
60
63
|
? emrConfiguration.transferWithinHospitalEncounterType
|
|
61
64
|
: null;
|
|
62
|
-
return createEncounter(patient, encounterType, visitUuid, obs, dateOfAdmission);
|
|
65
|
+
return createEncounter(patient, encounterType, visitUuid, obs, dateOfAdmission, formUuid);
|
|
63
66
|
};
|
|
64
67
|
|
|
65
68
|
return { admitPatient, isLoadingEmrConfiguration, errorFetchingEmrConfiguration };
|