gave these models `modified` rows

This commit is contained in:
Jeff Balogh 2010-01-04 20:08:48 -05:00
Родитель f7929504db
Коммит 50a804f1e4
2 изменённых файлов: 4 добавлений и 11 удалений

Просмотреть файл

@ -1,5 +1,3 @@
from datetime import datetime
from django.conf import settings
from django.db import models
@ -106,10 +104,9 @@ class AddonType(amo.ModelBase):
return unicode(self.name)
class BlacklistedGuid(models.Model):
class BlacklistedGuid(amo.ModelBase):
guid = models.CharField(max_length=255, unique=True)
created = models.DateTimeField(default=datetime.now, editable=False)
class Meta:
db_table = 'blacklisted_guids'

Просмотреть файл

@ -2,12 +2,11 @@ from datetime import datetime
from django.db import models
import caching
import amo
class Approval(caching.CachingMixin, models.Model):
class Approval(amo.ModelBase):
created = models.DateTimeField(default=datetime.now)
reviewtype = models.CharField(max_length=10, default='pending')
action = models.IntegerField(default=0)
os = models.CharField(max_length=255, default='')
@ -19,8 +18,5 @@ class Approval(caching.CachingMixin, models.Model):
#file = models.ForeignKey('files.File')
reply_to = models.ForeignKey('self', null=True, db_column='reply_to')
objects = caching.CachingManager()
class Meta:
class Meta(amo.ModelBase.Meta):
db_table = 'approvals'
get_latest_by = 'created'