sdi/models.py
changeset 5 6c4b3796a608
parent 4 ac7eaa878437
child 6 3b3c5f11af8e
--- a/sdi/models.py	Sat May 29 09:16:38 2010 +0530
+++ b/sdi/models.py	Sat May 29 09:36:16 2010 +0530
@@ -4,6 +4,20 @@
                   ("F", "Female"),
                  )
 
+PYTHON_KNOWLEDGE_CHOICES = (("5", "Written production level code in Python"),
+                            ("4", "Been using Python for quite some time"),
+                            ("3", "Solved some basic problems using Python"),
+                            ("2", "I know for sure that Python is a language"),
+                            ("1", "No clue what Python is"),
+                           )
+
+SAGE_KNOWLEDGE_CHOICES = (("5", "Written production level code in Sage"),
+                          ("4", "Been using Sage for quite some time"),
+                          ("3", "Solved some basic problems using Sage"),
+                          ("2", "I know for sure that Sage is a language"),
+                          ("1", "No clue what Sage is"),
+                         )
+
 LIKELINESS_CHOICES = (('5', "Will attend at any cost"),
                       ('4', "Will attend most probably"),
                       ('3', "Unsure of attending"),
@@ -11,7 +25,6 @@
                       ('1', "Will not attend"),
                      )
 
-
 class Registrant(models.Model):
     """ A model to hold the details of registered users.
     """
@@ -25,14 +38,14 @@
     affiliated_to = models.CharField(max_length=30, required=True)
 
     topics_interested = models.TextField()
-    knowledge_of_python = models.TextField()
-    need_for_python_workshop = models.BooleanField()
-    knowledge_of_sage = models.TextField()
+    knowledge_of_python = models.CharField(max_length=1, required=True, choices=PYTHON_KNOWLEDGE_CHOICES)
+    need_for_python_workshop = models.BooleanField(verbose_name="Do you need a workshop on Python before you attend Sage Days", 
+                                                   required=True)
+    knowledge_of_sage = models.CharField(max_length=1, required=True, choices=SAGE_KNOWLEDGE_CHOICES)
+    tools_used = models.TextField(help_text="Ex: Scilab, Mathematica, Matlab etc.", verbose_name="Other tools used")
 
-    tools_used = models.TextField()
-
+    address = models.TextField(help_text="To send DVD containing tutorials on Python if required.")
     phone_num = models.CharField(max_length=15, required=True)
-    address = models.TextField()
 
     likeliness_of_attending = models.CharField(max_length=1, required=True, choices=LIKELINESS_CHOICES)