refactor: improve code readability and consistency in api.ts and common.json
This commit is contained in:
@@ -1,17 +1,65 @@
|
||||
import {
|
||||
CreditCard,
|
||||
LayoutDashboard,
|
||||
Settings,
|
||||
Users,
|
||||
Database,
|
||||
UserCog,
|
||||
CreditCard,
|
||||
// People (Members + Access)
|
||||
UserCheck,
|
||||
UserPlus,
|
||||
IdCard,
|
||||
ClipboardList,
|
||||
KeyRound,
|
||||
// Courses
|
||||
GraduationCap,
|
||||
CalendarDays,
|
||||
MapPin,
|
||||
UserRound,
|
||||
// Events
|
||||
CalendarHeart,
|
||||
Ticket,
|
||||
PartyPopper,
|
||||
// Bookings
|
||||
Hotel,
|
||||
Calendar,
|
||||
BedDouble,
|
||||
Contact,
|
||||
CalendarRange,
|
||||
// Finance
|
||||
Wallet,
|
||||
Receipt,
|
||||
Landmark,
|
||||
BarChart3,
|
||||
// Documents
|
||||
FileText,
|
||||
FilePlus,
|
||||
FileStack,
|
||||
// Newsletter
|
||||
Mail,
|
||||
Globe,
|
||||
MailPlus,
|
||||
FileCode,
|
||||
// Site Builder
|
||||
PanelTop,
|
||||
Newspaper,
|
||||
Palette,
|
||||
// Fisheries
|
||||
Fish,
|
||||
Waves,
|
||||
Anchor,
|
||||
BookOpen,
|
||||
ShieldCheck,
|
||||
Trophy,
|
||||
// Meetings
|
||||
BookMarked,
|
||||
ListChecks,
|
||||
ScrollText,
|
||||
// Association (Verband)
|
||||
Building2,
|
||||
Network,
|
||||
SearchCheck,
|
||||
Share2,
|
||||
PieChart,
|
||||
LayoutTemplate,
|
||||
// Modules
|
||||
Database,
|
||||
} from 'lucide-react';
|
||||
|
||||
import { NavigationConfigSchema } from '@kit/ui/navigation-schema';
|
||||
@@ -21,101 +69,499 @@ import pathsConfig from '~/config/paths.config';
|
||||
|
||||
const iconClasses = 'w-4';
|
||||
|
||||
const getRoutes = (account: string) => [
|
||||
const getRoutes = (account: string) => {
|
||||
const routes: Array<
|
||||
| {
|
||||
label: string;
|
||||
collapsible?: boolean;
|
||||
collapsed?: boolean;
|
||||
children: Array<
|
||||
| {
|
||||
label: string;
|
||||
path: string;
|
||||
Icon: React.ReactNode;
|
||||
highlightMatch?: string;
|
||||
}
|
||||
| undefined
|
||||
>;
|
||||
}
|
||||
| { divider: true }
|
||||
> = [
|
||||
// ── Dashboard ──
|
||||
{
|
||||
label: 'common:routes.dashboard',
|
||||
children: [
|
||||
{
|
||||
label: 'common:routes.dashboard',
|
||||
path: pathsConfig.app.accountHome.replace('[account]', account),
|
||||
Icon: <LayoutDashboard className={iconClasses} />,
|
||||
highlightMatch: `${pathsConfig.app.home}$`,
|
||||
},
|
||||
],
|
||||
},
|
||||
];
|
||||
|
||||
// ── People (Members + Access) ──
|
||||
{
|
||||
label: 'common.routes.application',
|
||||
const peopleChildren: Array<{
|
||||
label: string;
|
||||
path: string;
|
||||
Icon: React.ReactNode;
|
||||
}> = [];
|
||||
|
||||
if (featureFlagsConfig.enableMemberManagement) {
|
||||
peopleChildren.push(
|
||||
{
|
||||
label: 'common:routes.clubMembers',
|
||||
path: createPath(pathsConfig.app.accountCmsMembers, account),
|
||||
Icon: <UserCheck className={iconClasses} />,
|
||||
},
|
||||
{
|
||||
label: 'common:routes.memberApplications',
|
||||
path: createPath(
|
||||
pathsConfig.app.accountCmsMembers + '/applications',
|
||||
account,
|
||||
),
|
||||
Icon: <UserPlus className={iconClasses} />,
|
||||
},
|
||||
{
|
||||
label: 'common:routes.memberPortal',
|
||||
path: createPath(
|
||||
pathsConfig.app.accountCmsMembers + '/portal',
|
||||
account,
|
||||
),
|
||||
Icon: <KeyRound className={iconClasses} />,
|
||||
},
|
||||
{
|
||||
label: 'common:routes.memberCards',
|
||||
path: createPath(
|
||||
pathsConfig.app.accountCmsMembers + '/cards',
|
||||
account,
|
||||
),
|
||||
Icon: <IdCard className={iconClasses} />,
|
||||
},
|
||||
{
|
||||
label: 'common:routes.memberDues',
|
||||
path: createPath(
|
||||
pathsConfig.app.accountCmsMembers + '/dues',
|
||||
account,
|
||||
),
|
||||
Icon: <ClipboardList className={iconClasses} />,
|
||||
},
|
||||
);
|
||||
}
|
||||
|
||||
// Admin users who can log in — always visible
|
||||
peopleChildren.push({
|
||||
label: 'common:routes.accessAndRoles',
|
||||
path: createPath(pathsConfig.app.accountMembers, account),
|
||||
Icon: <UserCog className={iconClasses} />,
|
||||
});
|
||||
|
||||
routes.push({
|
||||
label: 'common:routes.people',
|
||||
collapsible: true,
|
||||
children: peopleChildren,
|
||||
});
|
||||
}
|
||||
|
||||
// ── Courses ──
|
||||
if (featureFlagsConfig.enableCourseManagement) {
|
||||
routes.push({
|
||||
label: 'common:routes.courseManagement',
|
||||
collapsible: true,
|
||||
children: [
|
||||
{
|
||||
label: 'common:routes.courseList',
|
||||
path: createPath(pathsConfig.app.accountCourses, account),
|
||||
Icon: <GraduationCap className={iconClasses} />,
|
||||
},
|
||||
{
|
||||
label: 'common:routes.courseCalendar',
|
||||
path: createPath(
|
||||
pathsConfig.app.accountCourses + '/calendar',
|
||||
account,
|
||||
),
|
||||
Icon: <CalendarDays className={iconClasses} />,
|
||||
},
|
||||
{
|
||||
label: 'common:routes.courseInstructors',
|
||||
path: createPath(
|
||||
pathsConfig.app.accountCourses + '/instructors',
|
||||
account,
|
||||
),
|
||||
Icon: <UserRound className={iconClasses} />,
|
||||
},
|
||||
{
|
||||
label: 'common:routes.courseLocations',
|
||||
path: createPath(
|
||||
pathsConfig.app.accountCourses + '/locations',
|
||||
account,
|
||||
),
|
||||
Icon: <MapPin className={iconClasses} />,
|
||||
},
|
||||
],
|
||||
});
|
||||
}
|
||||
|
||||
// ── Events ──
|
||||
routes.push({
|
||||
label: 'common:routes.eventManagement',
|
||||
collapsible: true,
|
||||
children: [
|
||||
{
|
||||
label: 'common.routes.dashboard',
|
||||
path: pathsConfig.app.accountHome.replace('[account]', account),
|
||||
Icon: <LayoutDashboard className={iconClasses} />,
|
||||
highlightMatch: `${pathsConfig.app.home}$`,
|
||||
label: 'common:routes.eventList',
|
||||
path: createPath('/home/[account]/events', account),
|
||||
Icon: <CalendarHeart className={iconClasses} />,
|
||||
},
|
||||
featureFlagsConfig.enableModuleBuilder
|
||||
? {
|
||||
label: 'common.routes.modules',
|
||||
path: createPath(pathsConfig.app.accountModules, account),
|
||||
Icon: <Database className={iconClasses} />,
|
||||
}
|
||||
: undefined,
|
||||
featureFlagsConfig.enableMemberManagement
|
||||
? {
|
||||
label: 'common.routes.cmsMembers',
|
||||
path: createPath(pathsConfig.app.accountCmsMembers, account),
|
||||
Icon: <UserCheck className={iconClasses} />,
|
||||
}
|
||||
: undefined,
|
||||
featureFlagsConfig.enableCourseManagement
|
||||
? {
|
||||
label: 'common.routes.courses',
|
||||
path: createPath(pathsConfig.app.accountCourses, account),
|
||||
Icon: <GraduationCap className={iconClasses} />,
|
||||
}
|
||||
: undefined,
|
||||
featureFlagsConfig.enableBookingManagement
|
||||
? {
|
||||
label: 'common.routes.bookings',
|
||||
path: createPath(pathsConfig.app.accountBookings, account),
|
||||
Icon: <Hotel className={iconClasses} />,
|
||||
}
|
||||
: undefined,
|
||||
{
|
||||
label: 'common.routes.events',
|
||||
path: createPath(`/home/[account]/events`, account),
|
||||
Icon: <Calendar className={iconClasses} />,
|
||||
label: 'common:routes.eventRegistrations',
|
||||
path: createPath('/home/[account]/events/registrations', account),
|
||||
Icon: <Ticket className={iconClasses} />,
|
||||
},
|
||||
featureFlagsConfig.enableSepaPayments
|
||||
? {
|
||||
label: 'common.routes.finance',
|
||||
path: createPath(pathsConfig.app.accountFinance, account),
|
||||
Icon: <Wallet className={iconClasses} />,
|
||||
}
|
||||
: undefined,
|
||||
featureFlagsConfig.enableDocumentGeneration
|
||||
? {
|
||||
label: 'common.routes.documents',
|
||||
path: createPath(pathsConfig.app.accountDocuments, account),
|
||||
Icon: <FileText className={iconClasses} />,
|
||||
}
|
||||
: undefined,
|
||||
featureFlagsConfig.enableNewsletter
|
||||
? {
|
||||
label: 'common.routes.newsletter',
|
||||
path: createPath(pathsConfig.app.accountNewsletter, account),
|
||||
Icon: <Mail className={iconClasses} />,
|
||||
}
|
||||
: undefined,
|
||||
{
|
||||
label: 'common.routes.siteBuilder',
|
||||
path: createPath(`/home/[account]/site-builder`, account),
|
||||
Icon: <Globe className={iconClasses} />,
|
||||
label: 'common:routes.holidayPasses',
|
||||
path: createPath('/home/[account]/events/holiday-passes', account),
|
||||
Icon: <PartyPopper className={iconClasses} />,
|
||||
},
|
||||
].filter(Boolean),
|
||||
},
|
||||
{
|
||||
label: 'common.routes.settings',
|
||||
],
|
||||
});
|
||||
|
||||
// ── Bookings ──
|
||||
if (featureFlagsConfig.enableBookingManagement) {
|
||||
routes.push({
|
||||
label: 'common:routes.bookingManagement',
|
||||
collapsible: true,
|
||||
children: [
|
||||
{
|
||||
label: 'common:routes.bookingList',
|
||||
path: createPath(pathsConfig.app.accountBookings, account),
|
||||
Icon: <Hotel className={iconClasses} />,
|
||||
},
|
||||
{
|
||||
label: 'common:routes.bookingCalendar',
|
||||
path: createPath(
|
||||
pathsConfig.app.accountBookings + '/calendar',
|
||||
account,
|
||||
),
|
||||
Icon: <CalendarRange className={iconClasses} />,
|
||||
},
|
||||
{
|
||||
label: 'common:routes.bookingRooms',
|
||||
path: createPath(pathsConfig.app.accountBookings + '/rooms', account),
|
||||
Icon: <BedDouble className={iconClasses} />,
|
||||
},
|
||||
{
|
||||
label: 'common:routes.bookingGuests',
|
||||
path: createPath(
|
||||
pathsConfig.app.accountBookings + '/guests',
|
||||
account,
|
||||
),
|
||||
Icon: <Contact className={iconClasses} />,
|
||||
},
|
||||
],
|
||||
});
|
||||
}
|
||||
|
||||
// ── Finance ──
|
||||
if (featureFlagsConfig.enableSepaPayments) {
|
||||
routes.push({
|
||||
label: 'common:routes.financeManagement',
|
||||
collapsible: true,
|
||||
children: [
|
||||
{
|
||||
label: 'common:routes.financeOverview',
|
||||
path: createPath(pathsConfig.app.accountFinance, account),
|
||||
Icon: <Wallet className={iconClasses} />,
|
||||
},
|
||||
{
|
||||
label: 'common:routes.financeInvoices',
|
||||
path: createPath(
|
||||
pathsConfig.app.accountFinance + '/invoices',
|
||||
account,
|
||||
),
|
||||
Icon: <Receipt className={iconClasses} />,
|
||||
},
|
||||
{
|
||||
label: 'common:routes.financeSepa',
|
||||
path: createPath(pathsConfig.app.accountFinance + '/sepa', account),
|
||||
Icon: <Landmark className={iconClasses} />,
|
||||
},
|
||||
{
|
||||
label: 'common:routes.financePayments',
|
||||
path: createPath(
|
||||
pathsConfig.app.accountFinance + '/payments',
|
||||
account,
|
||||
),
|
||||
Icon: <BarChart3 className={iconClasses} />,
|
||||
},
|
||||
],
|
||||
});
|
||||
}
|
||||
|
||||
// ── Documents ──
|
||||
if (featureFlagsConfig.enableDocumentGeneration) {
|
||||
routes.push({
|
||||
label: 'common:routes.documentManagement',
|
||||
collapsible: true,
|
||||
children: [
|
||||
{
|
||||
label: 'common:routes.documentOverview',
|
||||
path: createPath(pathsConfig.app.accountDocuments, account),
|
||||
Icon: <FileText className={iconClasses} />,
|
||||
},
|
||||
{
|
||||
label: 'common:routes.documentGenerate',
|
||||
path: createPath(
|
||||
pathsConfig.app.accountDocuments + '/generate',
|
||||
account,
|
||||
),
|
||||
Icon: <FilePlus className={iconClasses} />,
|
||||
},
|
||||
{
|
||||
label: 'common:routes.documentTemplates',
|
||||
path: createPath(
|
||||
pathsConfig.app.accountDocuments + '/templates',
|
||||
account,
|
||||
),
|
||||
Icon: <FileStack className={iconClasses} />,
|
||||
},
|
||||
],
|
||||
});
|
||||
}
|
||||
|
||||
// ── Newsletter ──
|
||||
if (featureFlagsConfig.enableNewsletter) {
|
||||
routes.push({
|
||||
label: 'common:routes.newsletterManagement',
|
||||
collapsible: true,
|
||||
children: [
|
||||
{
|
||||
label: 'common:routes.newsletterCampaigns',
|
||||
path: createPath(pathsConfig.app.accountNewsletter, account),
|
||||
Icon: <Mail className={iconClasses} />,
|
||||
},
|
||||
{
|
||||
label: 'common:routes.newsletterNew',
|
||||
path: createPath(pathsConfig.app.accountNewsletter + '/new', account),
|
||||
Icon: <MailPlus className={iconClasses} />,
|
||||
},
|
||||
{
|
||||
label: 'common:routes.newsletterTemplates',
|
||||
path: createPath(
|
||||
pathsConfig.app.accountNewsletter + '/templates',
|
||||
account,
|
||||
),
|
||||
Icon: <FileCode className={iconClasses} />,
|
||||
},
|
||||
],
|
||||
});
|
||||
}
|
||||
|
||||
// ── Site Builder ──
|
||||
if (featureFlagsConfig.enableSiteBuilder) {
|
||||
routes.push({
|
||||
label: 'common:routes.siteBuilder',
|
||||
collapsible: true,
|
||||
children: [
|
||||
{
|
||||
label: 'common:routes.sitePages',
|
||||
path: createPath(pathsConfig.app.accountSiteBuilder, account),
|
||||
Icon: <PanelTop className={iconClasses} />,
|
||||
},
|
||||
{
|
||||
label: 'common:routes.sitePosts',
|
||||
path: createPath(
|
||||
pathsConfig.app.accountSiteBuilder + '/posts',
|
||||
account,
|
||||
),
|
||||
Icon: <Newspaper className={iconClasses} />,
|
||||
},
|
||||
{
|
||||
label: 'common:routes.siteSettings',
|
||||
path: createPath(
|
||||
pathsConfig.app.accountSiteBuilder + '/settings',
|
||||
account,
|
||||
),
|
||||
Icon: <Palette className={iconClasses} />,
|
||||
},
|
||||
],
|
||||
});
|
||||
}
|
||||
|
||||
// ── Custom Modules ──
|
||||
if (featureFlagsConfig.enableModuleBuilder) {
|
||||
routes.push({
|
||||
label: 'common:routes.customModules',
|
||||
collapsible: true,
|
||||
collapsed: true,
|
||||
children: [
|
||||
{
|
||||
label: 'common:routes.moduleList',
|
||||
path: createPath(pathsConfig.app.accountModules, account),
|
||||
Icon: <Database className={iconClasses} />,
|
||||
},
|
||||
],
|
||||
});
|
||||
}
|
||||
|
||||
// ── Fisheries ──
|
||||
if (featureFlagsConfig.enableFischerei) {
|
||||
routes.push({
|
||||
label: 'common:routes.fisheriesManagement',
|
||||
collapsible: true,
|
||||
children: [
|
||||
{
|
||||
label: 'common:routes.fisheriesOverview',
|
||||
path: createPath(pathsConfig.app.accountFischerei, account),
|
||||
Icon: <Fish className={iconClasses} />,
|
||||
},
|
||||
{
|
||||
label: 'common:routes.fisheriesWaters',
|
||||
path: createPath(
|
||||
pathsConfig.app.accountFischerei + '/waters',
|
||||
account,
|
||||
),
|
||||
Icon: <Waves className={iconClasses} />,
|
||||
},
|
||||
{
|
||||
label: 'common:routes.fisheriesLeases',
|
||||
path: createPath(
|
||||
pathsConfig.app.accountFischerei + '/leases',
|
||||
account,
|
||||
),
|
||||
Icon: <Anchor className={iconClasses} />,
|
||||
},
|
||||
{
|
||||
label: 'common:routes.fisheriesCatchBooks',
|
||||
path: createPath(
|
||||
pathsConfig.app.accountFischerei + '/catch-books',
|
||||
account,
|
||||
),
|
||||
Icon: <BookOpen className={iconClasses} />,
|
||||
},
|
||||
{
|
||||
label: 'common:routes.fisheriesPermits',
|
||||
path: createPath(
|
||||
pathsConfig.app.accountFischerei + '/permits',
|
||||
account,
|
||||
),
|
||||
Icon: <ShieldCheck className={iconClasses} />,
|
||||
},
|
||||
{
|
||||
label: 'common:routes.fisheriesCompetitions',
|
||||
path: createPath(
|
||||
pathsConfig.app.accountFischerei + '/competitions',
|
||||
account,
|
||||
),
|
||||
Icon: <Trophy className={iconClasses} />,
|
||||
},
|
||||
],
|
||||
});
|
||||
}
|
||||
|
||||
// ── Meeting Protocols ──
|
||||
if (featureFlagsConfig.enableMeetingProtocols) {
|
||||
routes.push({
|
||||
label: 'common:routes.meetingProtocols',
|
||||
collapsible: true,
|
||||
children: [
|
||||
{
|
||||
label: 'common:routes.meetingsOverview',
|
||||
path: createPath(pathsConfig.app.accountMeetings, account),
|
||||
Icon: <BookMarked className={iconClasses} />,
|
||||
},
|
||||
{
|
||||
label: 'common:routes.meetingsProtocols',
|
||||
path: createPath(
|
||||
pathsConfig.app.accountMeetings + '/protocols',
|
||||
account,
|
||||
),
|
||||
Icon: <ScrollText className={iconClasses} />,
|
||||
},
|
||||
{
|
||||
label: 'common:routes.meetingsTasks',
|
||||
path: createPath(pathsConfig.app.accountMeetings + '/tasks', account),
|
||||
Icon: <ListChecks className={iconClasses} />,
|
||||
},
|
||||
],
|
||||
});
|
||||
}
|
||||
|
||||
// ── Association Management (Verband) ──
|
||||
if (featureFlagsConfig.enableVerbandsverwaltung) {
|
||||
routes.push({
|
||||
label: 'common:routes.associationManagement',
|
||||
collapsible: true,
|
||||
children: [
|
||||
{
|
||||
label: 'common:routes.associationOverview',
|
||||
path: createPath(pathsConfig.app.accountVerband, account),
|
||||
Icon: <Building2 className={iconClasses} />,
|
||||
},
|
||||
{
|
||||
label: 'common:routes.associationHierarchy',
|
||||
path: createPath(
|
||||
pathsConfig.app.accountVerband + '/hierarchy',
|
||||
account,
|
||||
),
|
||||
Icon: <Network className={iconClasses} />,
|
||||
},
|
||||
{
|
||||
label: 'common:routes.associationMemberSearch',
|
||||
path: createPath(
|
||||
pathsConfig.app.accountVerband + '/members',
|
||||
account,
|
||||
),
|
||||
Icon: <SearchCheck className={iconClasses} />,
|
||||
},
|
||||
{
|
||||
label: 'common:routes.associationEvents',
|
||||
path: createPath(pathsConfig.app.accountVerband + '/events', account),
|
||||
Icon: <Share2 className={iconClasses} />,
|
||||
},
|
||||
{
|
||||
label: 'common:routes.associationReporting',
|
||||
path: createPath(
|
||||
pathsConfig.app.accountVerband + '/reporting',
|
||||
account,
|
||||
),
|
||||
Icon: <PieChart className={iconClasses} />,
|
||||
},
|
||||
{
|
||||
label: 'common:routes.associationTemplates',
|
||||
path: createPath(
|
||||
pathsConfig.app.accountVerband + '/templates',
|
||||
account,
|
||||
),
|
||||
Icon: <LayoutTemplate className={iconClasses} />,
|
||||
},
|
||||
],
|
||||
});
|
||||
}
|
||||
|
||||
// ── Administration ──
|
||||
routes.push({
|
||||
label: 'common:routes.administration',
|
||||
collapsible: false,
|
||||
children: [
|
||||
{
|
||||
label: 'common.routes.settings',
|
||||
label: 'common:routes.accountSettings',
|
||||
path: createPath(pathsConfig.app.accountSettings, account),
|
||||
Icon: <Settings className={iconClasses} />,
|
||||
},
|
||||
{
|
||||
label: 'common.routes.members',
|
||||
path: createPath(pathsConfig.app.accountMembers, account),
|
||||
Icon: <Users className={iconClasses} />,
|
||||
},
|
||||
featureFlagsConfig.enableTeamAccountBilling
|
||||
? {
|
||||
label: 'common.routes.billing',
|
||||
label: 'common:routes.billing',
|
||||
path: createPath(pathsConfig.app.accountBilling, account),
|
||||
Icon: <CreditCard className={iconClasses} />,
|
||||
}
|
||||
: undefined,
|
||||
].filter(Boolean),
|
||||
},
|
||||
];
|
||||
],
|
||||
});
|
||||
|
||||
return routes;
|
||||
};
|
||||
|
||||
export function getTeamAccountSidebarConfig(account: string) {
|
||||
return NavigationConfigSchema.parse({
|
||||
|
||||
@@ -61,24 +61,83 @@
|
||||
"routes": {
|
||||
"home": "Startseite",
|
||||
"account": "Konto",
|
||||
"members": "Mitglieder",
|
||||
"billing": "Abrechnung",
|
||||
"dashboard": "Dashboard",
|
||||
"settings": "Einstellungen",
|
||||
"profile": "Profil",
|
||||
"application": "Anwendung",
|
||||
"modules": "Module",
|
||||
"cmsMembers": "Mitglieder",
|
||||
"courses": "Kurse",
|
||||
"bookings": "Buchungen",
|
||||
"finance": "Finanzen",
|
||||
"documents": "Dokumente",
|
||||
"newsletter": "Newsletter",
|
||||
"events": "Veranstaltungen",
|
||||
|
||||
"people": "Personen",
|
||||
"clubMembers": "Vereinsmitglieder",
|
||||
"memberApplications": "Aufnahmeanträge",
|
||||
"memberPortal": "Mitgliederportal",
|
||||
"memberCards": "Mitgliedsausweise",
|
||||
"memberDues": "Beitragskategorien",
|
||||
"accessAndRoles": "Zugänge & Rollen",
|
||||
|
||||
"courseManagement": "Kursverwaltung",
|
||||
"courseList": "Alle Kurse",
|
||||
"courseCalendar": "Kurskalender",
|
||||
"courseInstructors": "Kursleiter",
|
||||
"courseLocations": "Standorte",
|
||||
|
||||
"eventManagement": "Veranstaltungen",
|
||||
"eventList": "Alle Veranstaltungen",
|
||||
"eventRegistrations": "Anmeldungen",
|
||||
"holidayPasses": "Ferienpässe",
|
||||
|
||||
"bookingManagement": "Buchungsverwaltung",
|
||||
"bookingList": "Alle Buchungen",
|
||||
"bookingCalendar": "Belegungskalender",
|
||||
"bookingRooms": "Zimmer",
|
||||
"bookingGuests": "Gäste",
|
||||
|
||||
"financeManagement": "Finanzen",
|
||||
"financeOverview": "Übersicht",
|
||||
"financeInvoices": "Rechnungen",
|
||||
"financeSepa": "SEPA-Einzüge",
|
||||
"financePayments": "Zahlungen",
|
||||
|
||||
"documentManagement": "Dokumente",
|
||||
"documentOverview": "Übersicht",
|
||||
"documentGenerate": "Generieren",
|
||||
"documentTemplates": "Vorlagen",
|
||||
|
||||
"newsletterManagement": "Newsletter",
|
||||
"newsletterCampaigns": "Kampagnen",
|
||||
"newsletterNew": "Neuer Newsletter",
|
||||
"newsletterTemplates": "Vorlagen",
|
||||
|
||||
"siteBuilder": "Website",
|
||||
"fischerei": "Fischerei",
|
||||
"meetings": "Sitzungsprotokolle",
|
||||
"verband": "Verbandsverwaltung"
|
||||
"sitePages": "Seiten",
|
||||
"sitePosts": "Beiträge",
|
||||
"siteSettings": "Einstellungen",
|
||||
|
||||
"customModules": "Benutzerdefinierte Module",
|
||||
"moduleList": "Alle Module",
|
||||
|
||||
"fisheriesManagement": "Fischerei",
|
||||
"fisheriesOverview": "Übersicht",
|
||||
"fisheriesWaters": "Gewässer",
|
||||
"fisheriesLeases": "Pachten",
|
||||
"fisheriesCatchBooks": "Fangbücher",
|
||||
"fisheriesPermits": "Erlaubnisscheine",
|
||||
"fisheriesCompetitions": "Wettbewerbe",
|
||||
|
||||
"meetingProtocols": "Sitzungsprotokolle",
|
||||
"meetingsOverview": "Übersicht",
|
||||
"meetingsProtocols": "Protokolle",
|
||||
"meetingsTasks": "Offene Aufgaben",
|
||||
|
||||
"associationManagement": "Verbandsverwaltung",
|
||||
"associationOverview": "Übersicht",
|
||||
"associationHierarchy": "Organisationsstruktur",
|
||||
"associationMemberSearch": "Verbandsweite Suche",
|
||||
"associationEvents": "Geteilte Veranstaltungen",
|
||||
"associationReporting": "Berichte",
|
||||
"associationTemplates": "Geteilte Vorlagen",
|
||||
|
||||
"administration": "Administration",
|
||||
"accountSettings": "Kontoeinstellungen"
|
||||
},
|
||||
"roles": {
|
||||
"owner": {
|
||||
|
||||
@@ -61,24 +61,83 @@
|
||||
"routes": {
|
||||
"home": "Home",
|
||||
"account": "Account",
|
||||
"members": "Members",
|
||||
"billing": "Billing",
|
||||
"dashboard": "Dashboard",
|
||||
"settings": "Settings",
|
||||
"profile": "Profile",
|
||||
"application": "Application",
|
||||
"modules": "Modules",
|
||||
"cmsMembers": "Members",
|
||||
"courses": "Courses",
|
||||
"bookings": "Bookings",
|
||||
"events": "Events",
|
||||
|
||||
"people": "People",
|
||||
"clubMembers": "Club Members",
|
||||
"memberApplications": "Applications",
|
||||
"memberPortal": "Member Portal",
|
||||
"memberCards": "Member Cards",
|
||||
"memberDues": "Dues Categories",
|
||||
"accessAndRoles": "Access & Roles",
|
||||
|
||||
"courseManagement": "Courses",
|
||||
"courseList": "All Courses",
|
||||
"courseCalendar": "Calendar",
|
||||
"courseInstructors": "Instructors",
|
||||
"courseLocations": "Locations",
|
||||
|
||||
"eventManagement": "Events",
|
||||
"eventList": "All Events",
|
||||
"eventRegistrations": "Registrations",
|
||||
"holidayPasses": "Holiday Passes",
|
||||
|
||||
"bookingManagement": "Bookings",
|
||||
"bookingList": "All Bookings",
|
||||
"bookingCalendar": "Availability Calendar",
|
||||
"bookingRooms": "Rooms",
|
||||
"bookingGuests": "Guests",
|
||||
|
||||
"financeManagement": "Finance",
|
||||
"financeOverview": "Overview",
|
||||
"financeInvoices": "Invoices",
|
||||
"financeSepa": "SEPA Batches",
|
||||
"financePayments": "Payments",
|
||||
|
||||
"documentManagement": "Documents",
|
||||
"documentOverview": "Overview",
|
||||
"documentGenerate": "Generate",
|
||||
"documentTemplates": "Templates",
|
||||
|
||||
"newsletterManagement": "Newsletter",
|
||||
"newsletterCampaigns": "Campaigns",
|
||||
"newsletterNew": "New Newsletter",
|
||||
"newsletterTemplates": "Templates",
|
||||
|
||||
"siteBuilder": "Website",
|
||||
"finance": "Finance",
|
||||
"documents": "Documents",
|
||||
"newsletter": "Newsletter",
|
||||
"fischerei": "Fisheries",
|
||||
"meetings": "Meeting Protocols",
|
||||
"verband": "Federation Management"
|
||||
"sitePages": "Pages",
|
||||
"sitePosts": "Posts",
|
||||
"siteSettings": "Settings",
|
||||
|
||||
"customModules": "Custom Modules",
|
||||
"moduleList": "All Modules",
|
||||
|
||||
"fisheriesManagement": "Fisheries",
|
||||
"fisheriesOverview": "Overview",
|
||||
"fisheriesWaters": "Waters",
|
||||
"fisheriesLeases": "Leases",
|
||||
"fisheriesCatchBooks": "Catch Books",
|
||||
"fisheriesPermits": "Permits",
|
||||
"fisheriesCompetitions": "Competitions",
|
||||
|
||||
"meetingProtocols": "Meeting Protocols",
|
||||
"meetingsOverview": "Overview",
|
||||
"meetingsProtocols": "Protocols",
|
||||
"meetingsTasks": "Open Tasks",
|
||||
|
||||
"associationManagement": "Association Management",
|
||||
"associationOverview": "Overview",
|
||||
"associationHierarchy": "Organization Structure",
|
||||
"associationMemberSearch": "Association-wide Search",
|
||||
"associationEvents": "Shared Events",
|
||||
"associationReporting": "Reports",
|
||||
"associationTemplates": "Shared Templates",
|
||||
|
||||
"administration": "Administration",
|
||||
"accountSettings": "Account Settings"
|
||||
},
|
||||
"roles": {
|
||||
"owner": {
|
||||
|
||||
@@ -165,7 +165,9 @@ async function getPatterns() {
|
||||
} catch {
|
||||
// Supabase unreachable — redirect to sign in
|
||||
const signIn = pathsConfig.auth.signIn;
|
||||
return NextResponse.redirect(new URL(signIn, req.nextUrl.origin).href);
|
||||
return NextResponse.redirect(
|
||||
new URL(signIn, req.nextUrl.origin).href,
|
||||
);
|
||||
}
|
||||
|
||||
const { origin, pathname: next } = req.nextUrl;
|
||||
|
||||
Reference in New Issue
Block a user