From 8c8cc97391634efb6108af05875cee14fe9cc572 Mon Sep 17 00:00:00 2001 From: Tom Walker Date: Sun, 29 Jun 2014 18:54:20 +0100 Subject: [PATCH] changed quiz/models fields to CommaSeparatedIntegerField when appropriate --- quiz/models.py | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/quiz/models.py b/quiz/models.py index 232ab3e..8d83359 100644 --- a/quiz/models.py +++ b/quiz/models.py @@ -143,8 +143,9 @@ class Progress(models.Model): user = models.OneToOneField('auth.User') # one user per progress class - score = models.TextField() # The god awful csv. - # Always end this with a comma, + # The god awful csv. Always end with a comma + score = models.CommaSeparatedIntegerField(max_length = 1024) + objects = ProgressManager() @@ -335,9 +336,10 @@ class Sitting(models.Model): quiz = models.ForeignKey(Quiz) - question_list = models.TextField() + question_list = models.CommaSeparatedIntegerField(max_length = 1024) - incorrect_questions = models.TextField(blank = True) + incorrect_questions = models.CommaSeparatedIntegerField(max_length = 1024, + blank = True) current_score = models.IntegerField() -- 2.39.5