diff --git a/client/src/components/ui/ItDropdownSelect.vue b/client/src/components/ui/ItDropdownSelect.vue index 8a9c3139..b1cb47df 100644 --- a/client/src/components/ui/ItDropdownSelect.vue +++ b/client/src/components/ui/ItDropdownSelect.vue @@ -5,17 +5,14 @@ import { computed } from "vue"; // https://stackoverflow.com/questions/64775876/ // https://stackoverflow.com/questions/64775876/vue-3-pass-reactive-object-to-component-with-two-way-binding interface Props { - modelValue?: { - id: string | number; - name: string; - }; + modelValue?: DropdownSelectable; items?: DropdownSelectable[]; borderless?: boolean; placeholderText?: string | null; } const emit = defineEmits<{ - (e: "update:modelValue", data: object): void; + (e: "update:modelValue", data: DropdownSelectable): void; }>(); const props = withDefaults(defineProps(), { diff --git a/client/src/pages/learningPath/learningPathPage/LearningPathProfileFilter.vue b/client/src/pages/learningPath/learningPathPage/LearningPathProfileFilter.vue index cad73d41..4dce5785 100644 --- a/client/src/pages/learningPath/learningPathPage/LearningPathProfileFilter.vue +++ b/client/src/pages/learningPath/learningPathPage/LearningPathProfileFilter.vue @@ -1,35 +1,44 @@ diff --git a/server/vbv_lernwelt/course/graphql/types.py b/server/vbv_lernwelt/course/graphql/types.py index cbec6854..934fa119 100644 --- a/server/vbv_lernwelt/course/graphql/types.py +++ b/server/vbv_lernwelt/course/graphql/types.py @@ -136,9 +136,7 @@ class CourseObjectType(DjangoObjectType): @staticmethod def resolve_profiles(root: Course, info, **kwargs): if root.configuration.is_vv: - return CourseProfile.objects.exclude(id=COURSE_PROFILE_ALL_ID).values_list( - "code", flat=True - ) + return CourseProfile.objects.values_list("code", flat=True) return [] @staticmethod