59 lines
1.4 KiB
Python
59 lines
1.4 KiB
Python
import factory
|
|
import wagtail_factories
|
|
|
|
from vbv_lernwelt.learnpath.models import LearningPath, Topic, Circle, LearningSequence, LearningUnit
|
|
from vbv_lernwelt.learnpath.models_learning_unit_content import VideoBlock, WebBasedTrainingBlock
|
|
|
|
|
|
class LearningPathFactory(wagtail_factories.PageFactory):
|
|
title = "Versicherungsvermittler/in"
|
|
|
|
class Meta:
|
|
model = LearningPath
|
|
|
|
|
|
class TopicFactory(factory.django.DjangoModelFactory):
|
|
title = "Gewinnen von Kunden"
|
|
is_visible = True
|
|
|
|
class Meta:
|
|
model = Topic
|
|
|
|
|
|
class CircleFactory(wagtail_factories.PageFactory):
|
|
title = "Gewinnen"
|
|
|
|
class Meta:
|
|
model = Circle
|
|
|
|
|
|
class LearningSequenceFactory(factory.django.DjangoModelFactory):
|
|
title = "Grundlagen"
|
|
|
|
class Meta:
|
|
model = LearningSequence
|
|
|
|
|
|
class LearningUnitFactory(wagtail_factories.PageFactory):
|
|
title = "Herzlich Willkommen"
|
|
|
|
class Meta:
|
|
model = LearningUnit
|
|
|
|
|
|
class VideoBlockFactory(wagtail_factories.StructBlockFactory):
|
|
title = "Ausbildung ist Pflicht"
|
|
url = "https://www.vbv.ch/fileadmin/vbv/Videos/Statements_Externe/Janos_M/Testimonial_Janos_Mischler_PositiveEffekte.mp4"
|
|
|
|
class Meta:
|
|
model = VideoBlock
|
|
|
|
|
|
class WebBasedTrainingBlockFactory(wagtail_factories.StructBlockFactory):
|
|
title = "Beispiel Rise Modul"
|
|
url = "https://docs.wagtail.org/en/stable/topics/streamfield.html"
|
|
|
|
class Meta:
|
|
model = WebBasedTrainingBlock
|
|
|