From 35256f7584b67f201946574c5f832ff1221ff1c6 Mon Sep 17 00:00:00 2001 From: Matthew Lemon Date: Fri, 13 Mar 2020 16:56:39 +0000 Subject: pop script now creates a dummy CAFSelfAssessment --- ctrack/organisations/management/commands/populate_db.py | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) (limited to 'ctrack/organisations') diff --git a/ctrack/organisations/management/commands/populate_db.py b/ctrack/organisations/management/commands/populate_db.py index edb070f..80ea5d0 100644 --- a/ctrack/organisations/management/commands/populate_db.py +++ b/ctrack/organisations/management/commands/populate_db.py @@ -173,6 +173,13 @@ class Command(BaseCommand): type=etf3, user=user, participants=[inspectors[1], p2], related_caf=_caf ) + # We want to create a CAF with a bunch of scoring now... + _caf2 = CAF.objects.get(pk=1) + _completer = Person.objects.get(pk=1) + caf_assessment = CAFSelfAssessment.objects.create( + caf_id=_caf2.id, completer_id=_completer.id, comments="Random Comments" + ) + # TODO - adapt this so that it records more than just Persons created self.stdout.write( self.style.SUCCESS( @@ -193,10 +200,3 @@ class Command(BaseCommand): name=random.choice(fnames), organisation=org, caf=caf, ) - # We want to create a CAF with a bunch of scoring now... - _caf2 = CAF.objects.get(pk=2) - _completer = Person.objects.get(pk=1) - caf_assessment = CAFSelfAssessment( - caf=_caf2, completer=_completer, comments="Random Comments" - ) - caf_assessment.save() -- cgit v1.2.3