2019-10-26 15:25:21 +00:00
|
|
|
from django.db import models
|
|
|
|
|
|
|
|
# Create your models here.
|
|
|
|
|
|
|
|
class Card(models.Model):
|
|
|
|
number = models.IntegerField("Card number", primary_key=True)
|
|
|
|
purchased = models.DateTimeField("Card purchased", auto_now_add=True)
|
2019-10-27 15:20:28 +00:00
|
|
|
delivered = models.DateTimeField("Card delivered to Oma", default=None, null=True, blank=True)
|
2019-10-26 15:39:14 +00:00
|
|
|
|
|
|
|
def __str__(self):
|
|
|
|
return str(self.number)
|