Added basic RBAC component BOD-232
This commit is contained in:
@@ -3,6 +3,7 @@ import OwnersPageComponent from "./owners.page.component";
|
||||
import { useTranslation } from "react-i18next";
|
||||
import { setBreadcrumbs } from "../../redux/application/application.actions";
|
||||
import { connect } from "react-redux";
|
||||
import RbacWrapper from "../../components/rbac-wrapper/rbac-wrapper.component";
|
||||
|
||||
const mapDispatchToProps = (dispatch) => ({
|
||||
setBreadcrumbs: (breadcrumbs) => dispatch(setBreadcrumbs(breadcrumbs)),
|
||||
@@ -15,6 +16,10 @@ export function OwnersPageContainer({ setBreadcrumbs }) {
|
||||
setBreadcrumbs([{ link: "/manage/owners", label: t("titles.bc.owners") }]);
|
||||
}, [t, setBreadcrumbs]);
|
||||
|
||||
return <OwnersPageComponent />;
|
||||
return (
|
||||
<RbacWrapper action="owners:list">
|
||||
<OwnersPageComponent />
|
||||
</RbacWrapper>
|
||||
);
|
||||
}
|
||||
export default connect(null, mapDispatchToProps)(OwnersPageContainer);
|
||||
|
||||
Reference in New Issue
Block a user