Skip to content

Commit

Permalink
Unable to launch Dispensing from the perspective
Browse files Browse the repository at this point in the history
  • Loading branch information
lucyjemutai committed Aug 24, 2023
1 parent 86a1c60 commit 85a09d3
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,11 @@ import React, { useEffect } from 'react';
import { attach, detach, ExtensionSlot } from '@openmrs/esm-framework';

const DispensingDashboard = () => {
useEffect(() => {
attach('ohri-dashboard-dispensing-slot', 'dispensing-dashboard');
return () => detach('ohri-dashboard-dispensing-slot', 'dispensing-dashboard');
}, []);

return <ExtensionSlot name="ohri-dashboard-dispensing-slot" state={{}} />;
};

Expand Down
8 changes: 7 additions & 1 deletion packages/esm-ohri-core-app/src/routes.json
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,13 @@
{
"name": "dispensing-ohri-dashboard-ext",
"slot": "dashboard-links-slot",
"component": "dispensingLink"
"component": "dispensingLink",
"meta": {
"title": "Dispensing",
"name": "dispensing",
"slot": "ohri-dispensing-dashboard-slot",
"isLink": true
}
},
{
"name": "ohri-dispensing-dashboard",
Expand Down

0 comments on commit 85a09d3

Please sign in to comment.