Private
Public Access
1
0

working but not passing test_analysis

This commit is contained in:
Sander Roosendaal
2020-03-30 21:56:04 +02:00
parent 619bb097e9
commit db4d16e8d9
9 changed files with 143 additions and 8 deletions

View File

@@ -3730,3 +3730,16 @@ class VideoAnalysis(models.Model):
def __str__(self):
return self.name
class ShareKey(models.Model):
location = models.TextField() # absolute path
token = models.CharField(max_length=40, primary_key=True)
creation_date = models.DateTimeField(auto_now_add=True)
expiration_seconds = models.BigIntegerField()
@property
def expired(self):
return self.creation_date + datetime.timedelta(self.expiration_seconds) < timezone.now()