mirror of https://github.com/kianby/stacosys
You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
27 lines
709 B
Python
27 lines
709 B
Python
10 years ago
|
#!/usr/bin/python
|
||
|
# -*- coding: UTF-8 -*-
|
||
|
|
||
|
from peewee import Model
|
||
|
from peewee import CharField
|
||
10 years ago
|
from peewee import TextField
|
||
10 years ago
|
from peewee import DateTimeField
|
||
|
from peewee import ForeignKeyField
|
||
6 years ago
|
from model.site import Site
|
||
7 years ago
|
from core.database import get_db
|
||
10 years ago
|
|
||
|
|
||
|
class Comment(Model):
|
||
|
url = CharField()
|
||
10 years ago
|
created = DateTimeField()
|
||
6 years ago
|
notified = DateTimeField(null=True,default=None)
|
||
10 years ago
|
published = DateTimeField(null=True, default=None)
|
||
10 years ago
|
author_name = CharField()
|
||
10 years ago
|
author_site = CharField(default='')
|
||
7 years ago
|
author_gravatar = CharField(default='')
|
||
6 years ago
|
ip = CharField(default='')
|
||
10 years ago
|
content = TextField()
|
||
10 years ago
|
site = ForeignKeyField(Site, related_name='site')
|
||
|
|
||
|
class Meta:
|
||
|
database = get_db()
|