2020-11-01 15:06:15 +01:00
|
|
|
from peewee import *
|
|
|
|
from playhouse.sqlite_ext import *
|
|
|
|
|
2020-11-04 13:31:25 +01:00
|
|
|
|
2020-11-01 15:06:15 +01:00
|
|
|
class Event(Model):
|
|
|
|
id = CharField(null=False, primary_key=True, max_length=30)
|
|
|
|
label = CharField(index=True, max_length=20)
|
|
|
|
camera = CharField(index=True, max_length=20)
|
|
|
|
start_time = DateTimeField()
|
|
|
|
end_time = DateTimeField()
|
|
|
|
top_score = FloatField()
|
|
|
|
false_positive = BooleanField()
|
2020-11-04 13:31:25 +01:00
|
|
|
zones = JSONField()
|
2020-11-15 15:50:49 +01:00
|
|
|
thumbnail = TextField()
|
2020-12-24 14:47:27 +01:00
|
|
|
has_clip = BooleanField(default=True)
|
|
|
|
has_snapshot = BooleanField(default=True)
|