Skip to content

Commit

Permalink
Merge pull request #99 from openimis/develop
Browse files Browse the repository at this point in the history
MERGING develop into release/24.04
  • Loading branch information
delcroip authored Mar 28, 2024
2 parents 825f8b3 + ccbb30e commit c968c64
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions src/components/AdminMainMenu.js
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@ import {
} from "../constants";

const ADMIN_MAIN_MENU_CONTRIBUTION_KEY = "admin.MainMenu";
const ADMIN_VOUCHER_MAIN_MENU_CONTRIBUTION_KEY = "admin.voucher.MainMenu";

class AdminMainMenu extends Component {
constructor(props) {
Expand All @@ -48,6 +49,12 @@ class AdminMainMenu extends Component {
});
}

entries.push(
...this.props.modulesManager
.getContribs(ADMIN_VOUCHER_MAIN_MENU_CONTRIBUTION_KEY)
.filter((c) => !c.filter || c.filter(rights)),
);

if (!entries.length) return null;

return (
Expand Down

0 comments on commit c968c64

Please sign in to comment.