Update path name
This commit is contained in:
parent
e8085831df
commit
4ac1c78a4f
|
|
@ -0,0 +1,41 @@
|
||||||
|
<script setup lang="ts">
|
||||||
|
import { Dialog, DialogDescription, DialogPanel, DialogTitle } from "@headlessui/vue";
|
||||||
|
import { ref } from "vue";
|
||||||
|
|
||||||
|
interface Props {
|
||||||
|
modelValue: boolean;
|
||||||
|
}
|
||||||
|
|
||||||
|
const props = withDefaults(defineProps<Props>(), {
|
||||||
|
modelValue: false,
|
||||||
|
});
|
||||||
|
|
||||||
|
const emits = defineEmits(["update:modelValue"]);
|
||||||
|
|
||||||
|
function setIsOpen(value: boolean) {
|
||||||
|
emits("update:modelValue", value);
|
||||||
|
}
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<template>
|
||||||
|
<Dialog :open="modelValue" @close="setIsOpen" class="relative z-50">
|
||||||
|
<div class="fixed inset-0 bg-black/30" aria-hidden="true"></div>
|
||||||
|
<div class="fixed inset-0 flex items-center justify-center p-4">
|
||||||
|
<DialogPanel class="w-full max-w-2xl bg-white px-8 pt-8 pb-4">
|
||||||
|
<DialogTitle class="flex flex-row relative mb-8">
|
||||||
|
<slot name="title"></slot>
|
||||||
|
<button
|
||||||
|
type="button"
|
||||||
|
class="w-4 h-4 absolute right-4 cursor-pointer"
|
||||||
|
@click="setIsOpen(false)"
|
||||||
|
>
|
||||||
|
<it-icon-close></it-icon-close>
|
||||||
|
</button>
|
||||||
|
</DialogTitle>
|
||||||
|
<DialogDescription> </DialogDescription>
|
||||||
|
|
||||||
|
<slot name="body"></slot>
|
||||||
|
</DialogPanel>
|
||||||
|
</div>
|
||||||
|
</Dialog>
|
||||||
|
</template>
|
||||||
|
|
@ -17,7 +17,7 @@ export const useMediaLibraryStore = defineStore({
|
||||||
selectedLearningPath: { id: 1, name: "Alle Lehrgänge" },
|
selectedLearningPath: { id: 1, name: "Alle Lehrgänge" },
|
||||||
availableLearningPaths: [
|
availableLearningPaths: [
|
||||||
{ id: 1, name: "Alle Lehrgänge" },
|
{ id: 1, name: "Alle Lehrgänge" },
|
||||||
{ id: 2, name: "Versicherungsvermittler/in" },
|
{ id: 2, name: "Versicherungsvermittler/-in" },
|
||||||
],
|
],
|
||||||
} as MediaLibraryStoreState;
|
} as MediaLibraryStoreState;
|
||||||
},
|
},
|
||||||
|
|
|
||||||
|
|
@ -11,7 +11,7 @@ describe("learningPath page", () => {
|
||||||
|
|
||||||
cy.get('[data-cy="learning-path-title"]').should(
|
cy.get('[data-cy="learning-path-title"]').should(
|
||||||
"contain",
|
"contain",
|
||||||
"Versicherungsvermittler/in"
|
"Versicherungsvermittler/-in"
|
||||||
);
|
);
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -10,7 +10,7 @@ def create_versicherungsvermittlerin_with_categories(
|
||||||
apps=None,
|
apps=None,
|
||||||
schema_editor=None,
|
schema_editor=None,
|
||||||
course_id=COURSE_VERSICHERUNGSVERMITTLERIN_ID,
|
course_id=COURSE_VERSICHERUNGSVERMITTLERIN_ID,
|
||||||
title="Versicherungsvermittler/in",
|
title="Versicherungsvermittler/-in",
|
||||||
):
|
):
|
||||||
if apps is not None:
|
if apps is not None:
|
||||||
Course = apps.get_model("course", "Course")
|
Course = apps.get_model("course", "Course")
|
||||||
|
|
|
||||||
|
|
@ -8,12 +8,12 @@ class CourseFactory(DjangoModelFactory):
|
||||||
class Meta:
|
class Meta:
|
||||||
model = Course
|
model = Course
|
||||||
|
|
||||||
title = "Versicherungsvermittler/in"
|
title = "Versicherungsvermittler/-in"
|
||||||
category_name = "Handlungsfeld"
|
category_name = "Handlungsfeld"
|
||||||
|
|
||||||
|
|
||||||
class CoursePageFactory(wagtail_factories.PageFactory):
|
class CoursePageFactory(wagtail_factories.PageFactory):
|
||||||
title = "Versicherungsvermittler/in"
|
title = "Versicherungsvermittler/-in"
|
||||||
|
|
||||||
class Meta:
|
class Meta:
|
||||||
model = CoursePage
|
model = CoursePage
|
||||||
|
|
|
||||||
|
|
@ -63,7 +63,7 @@ def command():
|
||||||
# course session Versicherungsvermittler/in
|
# course session Versicherungsvermittler/in
|
||||||
cs = CourseSession.objects.create(
|
cs = CourseSession.objects.create(
|
||||||
course_id=COURSE_VERSICHERUNGSVERMITTLERIN_ID,
|
course_id=COURSE_VERSICHERUNGSVERMITTLERIN_ID,
|
||||||
title="Versicherungsvermittler/in",
|
title="Versicherungsvermittler/-in",
|
||||||
)
|
)
|
||||||
for user_data in default_users:
|
for user_data in default_users:
|
||||||
CourseSessionUser.objects.create(
|
CourseSessionUser.objects.create(
|
||||||
|
|
|
||||||
|
|
@ -24,7 +24,7 @@ from vbv_lernwelt.learnpath.models_learning_unit_content import (
|
||||||
|
|
||||||
|
|
||||||
class LearningPathFactory(wagtail_factories.PageFactory):
|
class LearningPathFactory(wagtail_factories.PageFactory):
|
||||||
title = "Versicherungsvermittler/in"
|
title = "Versicherungsvermittler/-in"
|
||||||
|
|
||||||
class Meta:
|
class Meta:
|
||||||
model = LearningPath
|
model = LearningPath
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue