This commit is contained in:
seb
2026-10-03 07:32:29 +02:00
parent bc4a1e0468
commit c79ece307c
19 changed files with 622 additions and 69 deletions

View File

@@ -17,6 +17,9 @@ import RequestQuoteIcon from '@mui/icons-material/RequestQuote';
import ShoppingCartIcon from '@mui/icons-material/ShoppingCart';
import LabelIcon from '@mui/icons-material/Label';
import TuneIcon from '@mui/icons-material/Tune';
import HistoryIcon from '@mui/icons-material/History';
import PublicIcon from '@mui/icons-material/Public';
import BarChartIcon from '@mui/icons-material/BarChart';
import { isKategorienPath } from './components/category/categoryRoute';
import { deliveryEditorAutomat } from './automats/deliveryEditorAutomat';
@@ -229,6 +232,29 @@ export const SUB_NAV = {
help: 'Kundengruppen für Staffelpreise und Rabatte verwalten',
},
],
'/infos': [
{
segment: '',
label: 'ArticleHistory',
title: 'ArticleHistory',
icon: HistoryIcon,
help: 'Historie aller Artikeländerungen und Ereignisse',
},
{
segment: 'globalhistory',
label: 'GlobalHistory',
title: 'GlobalHistory',
icon: PublicIcon,
help: 'Globale System- und Änderungshistorie',
},
{
segment: 'statistics',
label: 'Statistics',
title: 'Statistics',
icon: BarChartIcon,
help: 'Statistische Auswertungen und Kennzahlen',
},
],
};
export function isNavItemActive(pathname, navPath) {
@@ -281,6 +307,11 @@ export function resolveActiveSub(pathname, sectionPath) {
return rest;
}
// Treat /infos/articlehistory as segment ''
if (sectionPath === '/infos' && rest === 'articlehistory') {
return '';
}
const active = subNav.find((item) => {
if (item.segment === 'kategorien') {
return isKategorienPath(pathname);