Closed brandones closed 4 years ago
Not the most elegant code I've ever written, but it does the trick.
Nested objects within arrays is still TODO.
Generates the following for esm-home:
"@openmrs/esm-home-app": { "buttons": { "enabled": true, "list": [ { "label": "Active Visits", // required // must be a string. "link": {"spa": false, "url": "/openmrs/coreapps/activeVisits.page?app=coreapps.activeVisits"}, // required "requiredPrivilege": "App: coreapps.activeVisits" // default: null // must be a string. }, {"label": "Patient Registration", "link": {"spa": true, "url": "/patient-registration"}}, {"label": "Capture Vitals", "link": {"spa": false, "url": "/openmrs/coreapps/findpatient/findPatient.page?app=referenceapplication.vitals"}, "requiredPrivilege": "App: referenceapplication.vitals"}, {"label": "Appointment Scheduling", "link": {"spa": false, "url": "/openmrs/appointmentschedulingui/home.page"}, "requiredPrivilege": "App: appointmentschedulingui.home"}, {"label": "Reports", "link": {"spa": false, "url": "/openmrs/reportingui/reportsapp/home.page"}, "requiredPrivilege": "View Reports"}, {"label": "Data Management", "link": {"spa": false, "url": "/openmrs/coreapps/datamanagement/dataManagement.page"}, "requiredPrivilege": "App: coreapps.dataManagement"}, {"label": "Configure Metadata", "link": {"spa": false, "url": "/openmrs/adminui/metadata/configureMetadata.page"}, "requiredPrivilege": "App: coreapps.configuremetadata"}, {"label": "System Administration", "link": {"spa": false, "url": "/openmrs/coreapps/systemadministration/systemAdministration.page"}, "requiredPrivilege": "App: coreapps.systemAdministration"}, ], } }
Not sure why the "Branch" build errored, it looks like it was using yarn, which this project doesn't use...?
yarn
Merging. Someone please take a look if you have a minute.
Not the most elegant code I've ever written, but it does the trick.
Nested objects within arrays is still TODO.
Generates the following for esm-home: