1 from django.db import models
2 from django.contrib.auth.models import User
4 # Create your models here.
5 class Event(models.Model):
6 name = models.CharField(max_length=50)
7 title = models.CharField(max_length=100)
8 slots = models.IntegerField()
12 return self.name + ' - ' + self.title
16 class Registration(models.Model):
17 person = models.ForeignKey(User)
18 event = models.ForeignKey(Event)
19 # vim: set sts=4 sw=4 expandtab: