From 6745431f170a4bcf623bb7ef33d2d162ed00e614 Mon Sep 17 00:00:00 2001 From: Daniel Egger Date: Wed, 5 Apr 2023 19:28:58 +0200 Subject: [PATCH] Add some FIXME-comments with reference to VBV-305 --- client/src/App.vue | 1 + client/src/stores/courseSessions.ts | 1 + client/src/stores/learningPath.ts | 1 + client/src/utils/eventBus.ts | 2 +- 4 files changed, 4 insertions(+), 1 deletion(-) diff --git a/client/src/App.vue b/client/src/App.vue index 590e001d..a0885600 100644 --- a/client/src/App.vue +++ b/client/src/App.vue @@ -26,6 +26,7 @@ onMounted(() => { log.debug("App mounted"); eventBus.on("switchedCourseSession", () => { + // FIXME: clean up with VBV-305 componentKey.value++; }); }); diff --git a/client/src/stores/courseSessions.ts b/client/src/stores/courseSessions.ts index fca86e8e..5aae6fce 100644 --- a/client/src/stores/courseSessions.ts +++ b/client/src/stores/courseSessions.ts @@ -100,6 +100,7 @@ export const useCourseSessionsStore = defineStore("courseSessions", () => { function switchCourseSession(courseSession: CourseSession) { log.debug("switchCourseSession", courseSession); selectedCourseSessionMap.value.set(courseSession.course.slug, courseSession.id); + // FIXME: clean up with VBV-305 eventBus.emit("switchedCourseSession", courseSession.id); } diff --git a/client/src/stores/learningPath.ts b/client/src/stores/learningPath.ts index 48b68e37..826fd7f3 100644 --- a/client/src/stores/learningPath.ts +++ b/client/src/stores/learningPath.ts @@ -109,6 +109,7 @@ export const useLearningPathStore = defineStore("learningPath", () => { eventBus.on("switchedCourseSession", (courseSession) => { log.debug("handle switchedCourseSession", courseSession); + // FIXME: clean up with VBV-305 reloadCompletionData(); }); diff --git a/client/src/utils/eventBus.ts b/client/src/utils/eventBus.ts index 32238197..788b978d 100644 --- a/client/src/utils/eventBus.ts +++ b/client/src/utils/eventBus.ts @@ -1,7 +1,7 @@ import mitt from "mitt"; export type MittEvents = { - // FIXME: + // FIXME: clean up with VBV-305 switchedCourseSession: number; };