feat: add Kaisertisch feature with view and integration in DiaryView
All checks were successful
Deploy tt-tagebuch / deploy (push) Successful in 56s
All checks were successful
Deploy tt-tagebuch / deploy (push) Successful in 56s
This commit is contained in:
@@ -65,6 +65,7 @@ export const SIDEBAR_NAVIGATION = {
|
||||
items: [
|
||||
{ to: '/members', icon: '👥', labelKey: 'navigation.members', permission: ['members', 'read'] },
|
||||
{ to: '/diary', icon: '📝', labelKey: 'navigation.diary', permission: ['diary', 'read'] },
|
||||
{ to: '/kaisertisch', icon: '🏓', label: 'Kaisertisch' },
|
||||
{
|
||||
to: '/calendar',
|
||||
icon: '📆',
|
||||
|
||||
@@ -18,6 +18,7 @@ const CreateClub = () => import('./views/CreateClub.vue');
|
||||
const ClubView = () => import('./views/ClubView.vue');
|
||||
const MembersView = () => import('./views/MembersView.vue');
|
||||
const DiaryView = () => import('./views/DiaryView.vue');
|
||||
const KaisertischView = () => import('./views/KaisertischView.vue');
|
||||
const CalendarView = () => import('./views/CalendarView.vue');
|
||||
const PendingApprovalsView = () => import('./views/PendingApprovalsView.vue');
|
||||
const ScheduleView = () => import('./views/ScheduleView.vue');
|
||||
@@ -175,6 +176,7 @@ const routes = [
|
||||
{ path: '/showclub/:clubId', name: 'show-club', component: ClubView, meta: withMeta({ products: fullAppProducts }) },
|
||||
{ path: '/members', name: 'members', component: MembersView, meta: withMeta({ products: fullAppProducts, permission: ['members', 'read'] }) },
|
||||
{ path: '/diary', name: 'diary', component: DiaryView, meta: withMeta({ products: trainerOnly }) },
|
||||
{ path: '/kaisertisch', name: 'kaisertisch', component: KaisertischView, meta: withMeta({ products: trainerOnly }) },
|
||||
{ path: '/calendar', name: 'calendar', component: CalendarView, meta: withMeta({ products: allProducts, anyPermission: [['diary', 'read'], ['schedule', 'read'], ['tournaments', 'read']] }) },
|
||||
{ path: '/pending-approvals', name: 'pending-approvals', component: PendingApprovalsView, meta: withMeta({ products: fullAppProducts, capability: 'approvals' }) },
|
||||
{ path: '/schedule', name: 'schedule', component: ScheduleView, meta: withMeta({ products: fullAppProducts, permission: ['schedule', 'read'] }) },
|
||||
|
||||
@@ -179,6 +179,14 @@
|
||||
>
|
||||
{{ $t('diary.trainingDaySummaryPdfShort') }}
|
||||
</button>
|
||||
<button
|
||||
v-if="date && date.id"
|
||||
type="button"
|
||||
aria-label="Kaisertisch für diesen Trainingstag starten"
|
||||
@click="startKaisertisch"
|
||||
>
|
||||
🏓 Kaisertisch starten
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
<div style="overflow: visible; position: relative;">
|
||||
@@ -2964,6 +2972,10 @@ export default {
|
||||
pdf.addTrainingPlan(this.currentClubName, this.date.date, this.trainingStart, this.trainingEnd, this.trainingPlan);
|
||||
pdf.save('trainingsplan.pdf');
|
||||
},
|
||||
startKaisertisch() {
|
||||
if (!this.date?.id) return;
|
||||
this.$router.push({ path: '/kaisertisch', query: { dateId: String(this.date.id) } });
|
||||
},
|
||||
async generateTrainingDayPDF() {
|
||||
if (!this.date || !this.participants || this.participants.length === 0) {
|
||||
this.showInfo('Fehler', 'Keine Teilnehmer für diesen Trainingstag vorhanden.', '', 'error');
|
||||
|
||||
203
frontend/src/views/KaisertischView.vue
Normal file
203
frontend/src/views/KaisertischView.vue
Normal file
File diff suppressed because one or more lines are too long
Reference in New Issue
Block a user