get_latest_by cleanups

Fix some that referenced non-existent attributes, and add the attribute
to other models.

Signed-off-by: Dan McGee <dan@archlinux.org>
This commit is contained in:
Dan McGee 2012-12-04 21:59:29 -06:00
parent f7fe73eff0
commit 4c69911982
2 changed files with 5 additions and 1 deletions

View File

@ -50,6 +50,7 @@ class UserProfile(models.Model):
class Meta:
db_table = 'user_profiles'
get_latest_by = 'last_modified'
verbose_name = 'Additional Profile Data'
verbose_name_plural = 'Additional Profile Data'
@ -80,6 +81,7 @@ class MasterKey(models.Model):
class Meta:
ordering = ('created',)
get_latest_by = 'created'
def __unicode__(self):
return u'%s, created %s' % (
@ -94,6 +96,8 @@ class PGPSignature(models.Model):
valid = models.BooleanField(default=True)
class Meta:
ordering = ('signer', 'signee')
get_latest_by = 'created'
verbose_name = 'PGP signature'
def __unicode__(self):

View File

@ -46,7 +46,7 @@ def __unicode__(self):
class Meta:
db_table = 'donors'
ordering = ('name',)
get_latest_by = 'when'
get_latest_by = 'created'
class Arch(models.Model):