added Meta class ordering by name to order speaker lists and dropdowns

This commit is contained in:
florapdx 2013-04-29 14:00:58 -07:00
parent f1b37c9833
commit 40b04240d4

View file

@ -26,12 +26,16 @@ class Speaker(models.Model):
default = datetime.datetime.now,
editable = False
)
class Meta:
ordering = ['name']
def __unicode__(self):
if self.user:
return self.name
else:
return "?"
def get_absolute_url(self):
return reverse("speaker_edit")