import { FG_Plugin } from '@flaschengeist/types'; import { PERMISSIONS } from '../permissions'; export const innerRoutes: FG_Plugin.MenuRoute[] = [ { title: 'Dienste', icon: 'mdi-briefcase', permissions: ['user'], route: { path: 'events', name: 'events', redirect: { name: 'schedule-overview' }, }, children: [ { title: 'Dienstübersicht', icon: 'mdi-account-group', shortcut: true, route: { path: 'schedule-overview', name: 'schedule-overview', component: () => import('../pages/EventOverview.vue'), }, }, { title: 'Dienstverwaltung', icon: 'mdi-account-details', shortcut: false, permissions: [PERMISSIONS.CREATE], route: { path: 'schedule-management', name: 'schedule-management', component: () => import('../pages/EventManagement.vue'), props: (route) => ({ date: route.query.date }), }, }, { title: 'Dienstanfragen', icon: 'mdi-account-switch', shortcut: false, route: { path: 'events-requests', name: 'events-requests', component: () => import('../pages/EventRequests.vue'), }, }, ], }, ]; export const privateRoutes: FG_Plugin.NamedRouteRecordRaw[] = [ { name: 'events-single-view', path: 'events/:id', component: () => import('../pages/EventPage.vue'), props: true }, { name: 'events-edit', path: 'events/:id/edit', component: () => import('../pages/EventPage.vue'), }, ];