From 5bcb76a60e084eda87381edb466553fb9b9f0843 Mon Sep 17 00:00:00 2001 From: Julian Krauser Date: Mon, 20 Jan 2025 12:43:18 +0100 Subject: [PATCH] change: enable calendar entry details for public --- .../calendar/ShowCalendarEntryModal.vue | 97 +++++++++++++++++++ src/stores/admin/navigation.ts | 2 +- src/views/public/calendar/Calendar.vue | 7 ++ 3 files changed, 105 insertions(+), 1 deletion(-) create mode 100644 src/components/public/calendar/ShowCalendarEntryModal.vue diff --git a/src/components/public/calendar/ShowCalendarEntryModal.vue b/src/components/public/calendar/ShowCalendarEntryModal.vue new file mode 100644 index 0000000..267db82 --- /dev/null +++ b/src/components/public/calendar/ShowCalendarEntryModal.vue @@ -0,0 +1,97 @@ + + + + + diff --git a/src/stores/admin/navigation.ts b/src/stores/admin/navigation.ts index a3f6eeb..782e42f 100644 --- a/src/stores/admin/navigation.ts +++ b/src/stores/admin/navigation.ts @@ -63,7 +63,7 @@ export const useNavigationStore = defineStore("navigation", { { key: "settings", title: "Einstellungen", - levelDefault: "qualification", + levelDefault: "award", } as topLevelNavigationModel, ] : []), diff --git a/src/views/public/calendar/Calendar.vue b/src/views/public/calendar/Calendar.vue index 0cc8d9d..956a34d 100644 --- a/src/views/public/calendar/Calendar.vue +++ b/src/views/public/calendar/Calendar.vue @@ -73,6 +73,7 @@ export default defineComponent({ weekText: "KW", allDaySlot: false, events: this.formattedItems, + eventClick: this.eventClick, }; }, }, @@ -92,6 +93,12 @@ export default defineComponent({ openLinkModal(e: any) { this.openModal(markRaw(defineAsyncComponent(() => import("@/components/public/calendar/CalendarLinkModal.vue")))); }, + eventClick(e: any) { + this.openModal( + markRaw(defineAsyncComponent(() => import("@/components/public/calendar/ShowCalendarEntryModal.vue"))), + this.calendars.find((c) => c.id == e.event.id) + ); + }, }, });