2011-11-18 14:01:06 +01:00
|
|
|
from django.db import models
|
|
|
|
|
2013-11-02 22:34:05 +01:00
|
|
|
|
2011-11-18 14:01:06 +01:00
|
|
|
class Event(models.Model):
|
|
|
|
dt = models.DateTimeField()
|
|
|
|
|
2013-11-02 22:34:05 +01:00
|
|
|
|
2011-11-25 10:25:43 +01:00
|
|
|
class MaybeEvent(models.Model):
|
|
|
|
dt = models.DateTimeField(blank=True, null=True)
|
|
|
|
|
2013-11-02 22:34:05 +01:00
|
|
|
|
2012-02-22 20:40:27 +01:00
|
|
|
class Session(models.Model):
|
|
|
|
name = models.CharField(max_length=20)
|
|
|
|
|
2013-11-02 22:34:05 +01:00
|
|
|
|
2012-02-22 20:40:27 +01:00
|
|
|
class SessionEvent(models.Model):
|
|
|
|
dt = models.DateTimeField()
|
2015-07-22 16:43:21 +02:00
|
|
|
session = models.ForeignKey(Session, models.CASCADE, related_name="events")
|
2012-02-22 20:40:27 +01:00
|
|
|
|
2013-11-02 22:34:05 +01:00
|
|
|
|
2011-11-18 14:01:06 +01:00
|
|
|
class Timestamp(models.Model):
|
|
|
|
created = models.DateTimeField(auto_now_add=True)
|
|
|
|
updated = models.DateTimeField(auto_now=True)
|
2012-05-01 10:40:25 +02:00
|
|
|
|
2013-11-02 22:34:05 +01:00
|
|
|
|
2012-05-01 10:40:25 +02:00
|
|
|
class AllDayEvent(models.Model):
|
|
|
|
day = models.DateField()
|
2021-07-01 15:19:09 +02:00
|
|
|
|
|
|
|
|
|
|
|
class DailyEvent(models.Model):
|
|
|
|
time = models.TimeField()
|