import { getAsyncLifecycle, getSyncLifecycle } from '@openmrs/esm-framework'; import { createOHRIDashboardLink, } from 'openmrs-esm-ohri-commons-lib'; import { patientMeta, patientEditMeta, patientCreateMeta, reportMeta } from '../navigation'; const moduleName = 'openmrs-esm-ohri-vn-app'; const options = { featureName: 'ohri-vn', moduleName, }; const PatientExtension = [ { id: 'ohri-patients-list', slot: 'ohri-patient-slot', load: getAsyncLifecycle(() => import('./PatientIndex'), { featureName: 'patient', moduleName, }), meta: patientMeta, online: true, offline: true, }, { id: 'patient-dashboard-ext', slot: 'dashboard-links-slot', load: getSyncLifecycle(createOHRIDashboardLink(patientMeta), options), meta: patientMeta, online: true, offline: true, }, //report { id: 'report-dashboard-ext', slot: 'dashboard-links-slot', load: getSyncLifecycle(createOHRIDashboardLink(reportMeta), options), meta: reportMeta, online: true, offline: true, }, //edit { id: 'ohri-patients-edit', slot: 'ohri-patient-edit-slot', load: getAsyncLifecycle(() => import('./PatientEdit'), { featureName: 'patient-edit', moduleName, }), meta: patientEditMeta, online: true, offline: true, }, { id: 'patient-edit-ext', slot: 'dashboard-globits-slot', load: getSyncLifecycle(createOHRIDashboardLink(patientEditMeta), options), meta: patientEditMeta, online: true, offline: true, }, //create { id: 'ohri-patients-create', slot: 'ohri-patient-create-slot', load: getAsyncLifecycle(() => import('./PatientCreate'), { featureName: 'patient-create', moduleName, }), meta: patientCreateMeta, online: true, offline: true, }, { id: 'patient-create-ext', slot: 'dashboard-globits-slot', load: getSyncLifecycle(createOHRIDashboardLink(patientCreateMeta), options), meta: patientCreateMeta, online: true, offline: true, }, ] export default PatientExtension;