Added basic RBAC component BOD-232

This commit is contained in:
Patrick Fic
2020-08-10 16:07:30 -07:00
parent 0df61a2701
commit 83c83ac06e
52 changed files with 670 additions and 288 deletions

View File

@@ -8,6 +8,7 @@ import AlertComponent from "../../components/alert/alert.component";
import { QUERY_PAYMENTS_FOR_EXPORT } from "../../graphql/accounting.queries";
import { setBreadcrumbs } from "../../redux/application/application.actions";
import { selectBodyshop } from "../../redux/user/user.selectors";
import RbacWrapper from "../../components/rbac-wrapper/rbac-wrapper.component";
const mapStateToProps = createStructuredSelector({
bodyshop: selectBodyshop,
@@ -35,10 +36,12 @@ export function AccountingPaymentsContainer({ bodyshop, setBreadcrumbs }) {
return (
<div>
<AccountingPaymentsTable
loadaing={loading}
payments={data ? data.payments : []}
/>
<RbacWrapper action="accounting:payments">
<AccountingPaymentsTable
loadaing={loading}
payments={data ? data.payments : []}
/>
</RbacWrapper>
</div>
);
}