feature/IO-3255-simplified-parts-management - Fix top level breadcrumbs, up deps
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
import { Tabs } from "antd";
|
||||
import queryString from "query-string";
|
||||
import React, { useEffect } from "react";
|
||||
import { useEffect } from "react";
|
||||
import { useTranslation } from "react-i18next";
|
||||
import { connect } from "react-redux";
|
||||
import { useLocation, useNavigate } from "react-router-dom";
|
||||
@@ -8,20 +8,17 @@ import { createStructuredSelector } from "reselect";
|
||||
import RbacWrapper from "../../components/rbac-wrapper/rbac-wrapper.component";
|
||||
import ShopVendorPageComponent from "../shop-vendor/shop-vendor.page.component";
|
||||
import { setBreadcrumbs, setSelectedHeader } from "../../redux/application/application.actions";
|
||||
import { selectBodyshop } from "../../redux/user/user.selectors";
|
||||
import InstanceRenderManager from "../../utils/instanceRenderMgr";
|
||||
import PartsShopInfoContainer from "../../components/parts-shop-info/parts-shop-info.container";
|
||||
|
||||
const mapStateToProps = createStructuredSelector({
|
||||
bodyshop: selectBodyshop
|
||||
});
|
||||
const mapStateToProps = createStructuredSelector({});
|
||||
|
||||
const mapDispatchToProps = (dispatch) => ({
|
||||
setSelectedHeader: (key) => dispatch(setSelectedHeader(key)),
|
||||
setBreadcrumbs: (breadcrumbs) => dispatch(setBreadcrumbs(breadcrumbs))
|
||||
});
|
||||
|
||||
export function PartsSettingsPage({ bodyshop, setSelectedHeader, setBreadcrumbs }) {
|
||||
export function PartsSettingsPage({ setSelectedHeader, setBreadcrumbs }) {
|
||||
const { t } = useTranslation();
|
||||
const history = useNavigate();
|
||||
const search = queryString.parse(useLocation().search);
|
||||
@@ -53,7 +50,7 @@ export function PartsSettingsPage({ bodyshop, setSelectedHeader, setBreadcrumbs
|
||||
const items = [
|
||||
{
|
||||
key: "shop",
|
||||
label: t("bodyshop.labels.shop_management"),
|
||||
label: t("bodyshop.labels.parts_shop_management"),
|
||||
children: (
|
||||
<RbacWrapper action="shop:config">
|
||||
<PartsShopInfoContainer />
|
||||
@@ -62,7 +59,7 @@ export function PartsSettingsPage({ bodyshop, setSelectedHeader, setBreadcrumbs
|
||||
},
|
||||
{
|
||||
key: "vendors",
|
||||
label: t("bodyshop.labels.vendor_management"),
|
||||
label: t("bodyshop.labels.parts_vendor_management"),
|
||||
children: (
|
||||
<RbacWrapper action="shop:vendors">
|
||||
<ShopVendorPageComponent />
|
||||
|
||||
Reference in New Issue
Block a user