upload/models.py
author Shantanu <shantanu@fossee.in>
Wed, 02 Sep 2009 19:34:48 +0530
changeset 2 4d2bbb2f3c4e
parent 0 5fb12cd6d64d
child 12 0a2b4e85a4ab
permissions -rw-r--r--
Added models and views.
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
0
5fb12cd6d64d Initial commit added django files.
Shantanu <shantanu@fossee.in>
parents:
diff changeset
     1
from django.db import models
5fb12cd6d64d Initial commit added django files.
Shantanu <shantanu@fossee.in>
parents:
diff changeset
     2
5fb12cd6d64d Initial commit added django files.
Shantanu <shantanu@fossee.in>
parents:
diff changeset
     3
# Create your models here.
2
4d2bbb2f3c4e Added models and views.
Shantanu <shantanu@fossee.in>
parents: 0
diff changeset
     4
4d2bbb2f3c4e Added models and views.
Shantanu <shantanu@fossee.in>
parents: 0
diff changeset
     5
class Participant(models.Model):
4d2bbb2f3c4e Added models and views.
Shantanu <shantanu@fossee.in>
parents: 0
diff changeset
     6
	LANGUAGE_CHOICES = (
4d2bbb2f3c4e Added models and views.
Shantanu <shantanu@fossee.in>
parents: 0
diff changeset
     7
		(1,'Assamese/Axomiya'),
4d2bbb2f3c4e Added models and views.
Shantanu <shantanu@fossee.in>
parents: 0
diff changeset
     8
		(2,'Bengali'),
4d2bbb2f3c4e Added models and views.
Shantanu <shantanu@fossee.in>
parents: 0
diff changeset
     9
		(3,'Bodo'),
4d2bbb2f3c4e Added models and views.
Shantanu <shantanu@fossee.in>
parents: 0
diff changeset
    10
		(4,'Dogri'),
4d2bbb2f3c4e Added models and views.
Shantanu <shantanu@fossee.in>
parents: 0
diff changeset
    11
		(5,'Gujarati'),
4d2bbb2f3c4e Added models and views.
Shantanu <shantanu@fossee.in>
parents: 0
diff changeset
    12
		(6,'Hindi'),
4d2bbb2f3c4e Added models and views.
Shantanu <shantanu@fossee.in>
parents: 0
diff changeset
    13
		(7,'Kannada'),
4d2bbb2f3c4e Added models and views.
Shantanu <shantanu@fossee.in>
parents: 0
diff changeset
    14
		(8,'Kashmiri'),
4d2bbb2f3c4e Added models and views.
Shantanu <shantanu@fossee.in>
parents: 0
diff changeset
    15
		(9,'Konkani'),
4d2bbb2f3c4e Added models and views.
Shantanu <shantanu@fossee.in>
parents: 0
diff changeset
    16
		(10,'Maithili'),
4d2bbb2f3c4e Added models and views.
Shantanu <shantanu@fossee.in>
parents: 0
diff changeset
    17
		(11,'Malayalam'),
4d2bbb2f3c4e Added models and views.
Shantanu <shantanu@fossee.in>
parents: 0
diff changeset
    18
		(12,'Manipuri'),
4d2bbb2f3c4e Added models and views.
Shantanu <shantanu@fossee.in>
parents: 0
diff changeset
    19
		(13,'Marathi'),
4d2bbb2f3c4e Added models and views.
Shantanu <shantanu@fossee.in>
parents: 0
diff changeset
    20
		(14,'Nepali'),
4d2bbb2f3c4e Added models and views.
Shantanu <shantanu@fossee.in>
parents: 0
diff changeset
    21
		(15,'Oriya'),
4d2bbb2f3c4e Added models and views.
Shantanu <shantanu@fossee.in>
parents: 0
diff changeset
    22
		(16,'Punjabi'),
4d2bbb2f3c4e Added models and views.
Shantanu <shantanu@fossee.in>
parents: 0
diff changeset
    23
		(17,'Sanskrit'),
4d2bbb2f3c4e Added models and views.
Shantanu <shantanu@fossee.in>
parents: 0
diff changeset
    24
		(18,'Santali'),
4d2bbb2f3c4e Added models and views.
Shantanu <shantanu@fossee.in>
parents: 0
diff changeset
    25
		(19,'Sindhi'),
4d2bbb2f3c4e Added models and views.
Shantanu <shantanu@fossee.in>
parents: 0
diff changeset
    26
		(20,'Tamil'),
4d2bbb2f3c4e Added models and views.
Shantanu <shantanu@fossee.in>
parents: 0
diff changeset
    27
		(21,'Telugu'),
4d2bbb2f3c4e Added models and views.
Shantanu <shantanu@fossee.in>
parents: 0
diff changeset
    28
		(22,'Urdu'),
4d2bbb2f3c4e Added models and views.
Shantanu <shantanu@fossee.in>
parents: 0
diff changeset
    29
   	)
4d2bbb2f3c4e Added models and views.
Shantanu <shantanu@fossee.in>
parents: 0
diff changeset
    30
   	CATEGORY_CHOICES = (
4d2bbb2f3c4e Added models and views.
Shantanu <shantanu@fossee.in>
parents: 0
diff changeset
    31
		(1,'Student at IIT'),
4d2bbb2f3c4e Added models and views.
Shantanu <shantanu@fossee.in>
parents: 0
diff changeset
    32
		(2,'Staff and family'),
4d2bbb2f3c4e Added models and views.
Shantanu <shantanu@fossee.in>
parents: 0
diff changeset
    33
		(3,'Faculty and family'),
4d2bbb2f3c4e Added models and views.
Shantanu <shantanu@fossee.in>
parents: 0
diff changeset
    34
		(4,'Others'),
4d2bbb2f3c4e Added models and views.
Shantanu <shantanu@fossee.in>
parents: 0
diff changeset
    35
   	)
4d2bbb2f3c4e Added models and views.
Shantanu <shantanu@fossee.in>
parents: 0
diff changeset
    36
	name = models.CharField(max_length = 50)
4d2bbb2f3c4e Added models and views.
Shantanu <shantanu@fossee.in>
parents: 0
diff changeset
    37
	email = models.EmailField()
4d2bbb2f3c4e Added models and views.
Shantanu <shantanu@fossee.in>
parents: 0
diff changeset
    38
	filename = models.FileField(upload_to = 'videos')
4d2bbb2f3c4e Added models and views.
Shantanu <shantanu@fossee.in>
parents: 0
diff changeset
    39
	language = models.CharField(max_length = 20, choices=LANGUAGE_CHOICES)
4d2bbb2f3c4e Added models and views.
Shantanu <shantanu@fossee.in>
parents: 0
diff changeset
    40
	phonenumber = models.CharField(max_length=15)
4d2bbb2f3c4e Added models and views.
Shantanu <shantanu@fossee.in>
parents: 0
diff changeset
    41
	age = models.IntegerField(max_length=3)
4d2bbb2f3c4e Added models and views.
Shantanu <shantanu@fossee.in>
parents: 0
diff changeset
    42
	category = models.CharField(max_length = 80, choices=CATEGORY_CHOICES)
4d2bbb2f3c4e Added models and views.
Shantanu <shantanu@fossee.in>
parents: 0
diff changeset
    43
4d2bbb2f3c4e Added models and views.
Shantanu <shantanu@fossee.in>
parents: 0
diff changeset
    44