1
0
mirror of https://github.com/r4sas/py-i2phosts synced 2025-01-22 12:34:17 +00:00

postkey/models.py: do not fill date_added automatically

Django uses localtime when using auto_add_now=True, but we wants an UTC
time. So, we will fill this field manually.
This commit is contained in:
Hidden Z 2010-11-15 19:00:51 +00:00
parent 52f4bc15e1
commit fa93084df3

View File

@ -6,7 +6,7 @@ class i2phost(models.Model):
# Maximum key length 616 bytes (to account for certs up to 100 bytes).
b64hash = models.CharField("Base 64 hash", max_length=616)
description = models.CharField("Description", max_length=4096, blank=True)
date_added = models.DateTimeField(auto_now_add=True)
date_added = models.DateTimeField(null=True, blank=True)
# Last time this host was up
last_seen = models.DateTimeField(null=True, blank=True)
# Scheduled expiration date