Skip to content

Commit c800d17

Browse files
committed
1 parent 2fa62fc commit c800d17

File tree

1 file changed

+10
-1
lines changed

1 file changed

+10
-1
lines changed

mysite/polls/models.py

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,12 @@
11
from django.db import models
22

3-
# Create your models here.
3+
4+
class Question(models.Model):
5+
question_text = models.CharField(max_length=200)
6+
pub_date = models.DateTimeField('date published')
7+
8+
9+
class Choice(models.Model):
10+
question = models.ForeignKey(Question)
11+
choice_text = models.CharField(max_length=200)
12+
votes = models.IntegerField(default=0)

0 commit comments

Comments
 (0)